app to create language test
| License: | MIT |
|---|
Create an AWS Ubuntu Machine using free tier account (Ubuntu 16.04 LTS) using key pair value
Create a New Security Group with inboud rules, that allows ssh from any ip and tcp request on port any port
Right click the ec2 instance and from networking, change security group and assign this security group
Connect to the machine using following command
$ ssh -i <yourpemfile.pem> ubuntu@<ip_address>
Setup Up Docker on your machine using following commands
$ sudo apt-get update
$ sudo apt-get install apt-transport-https ca-certificates curl gnupg-agent software-properties-common
$ curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
$ sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
$ sudo apt-get update
$ sudo apt-get install docker-ce
$ sudo apt-get install docker-compose
Go to your freenom.com or any domain name service provider, create a domain and edit the freenom dns record so as to point to your server ipaddress
Go to AWS account and create a publicly accessible s3 bucket and under acounts section create api keys
- Go the repository and edit following files:
- envs > .production > .caddy ---> change the languagetest.tk domain to your domain name
- envs > .production > .django ---> change the DJANGO_ALLOWED_HOSTS languagetest.tk domain to your domain name
- envs > .production > .django ---> edit the followings:
- Once you have completed docker installation, including docker and docker-compose, follow following instructions
$ git clone https://github.com/kennedy-dev/language-test
$ cd language-test
To run the application, we need to build it first using following command
$ sudo docker-compose -f production.yml build
To run the application, we need to build it first using following command
$ sudo docker-compose -f production.yml run django python manage.py makemigrations
To run the application, we need to build it first using following command
$ sudo docker-compose -f production.yml run django python manage.py migrate
To create an admin account, use this command:
$ sudo docker-compose -f production.yml run django python manage.py createsuperuser
To create an admin account, use this command:
$ sudo docker-compose -f production.yml run django python manage.py runscript loaddata
To run the application, we need to build it first using following command
$ sudo nohup docker-compose -f production.yml up --build
- Go mailgun.com
- create a free account
- get api credentials
- sudo nano .env/.production/.django
e. Go to admin panel, edit the sites to match your site e. Enter the api credentials you get from mailgun
MAILGUN_API_KEY=
DJANGO_SERVER_EMAIL=
MAILGUN_DOMAIN=
- Go to your browser and type: http://<ip_address>
- Go to https://languagetest.tk/