Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/micnguyen266/django-terraform-ansible-demo
Simple web app using Terraform, Ansible, Nginx, Gunicorn and Django in Linode
https://github.com/micnguyen266/django-terraform-ansible-demo
ansible django gunicorn linode linode-api linux nginx terraform virtualization yaml
Last synced: about 1 month ago
JSON representation
Simple web app using Terraform, Ansible, Nginx, Gunicorn and Django in Linode
- Host: GitHub
- URL: https://github.com/micnguyen266/django-terraform-ansible-demo
- Owner: micnguyen266
- License: mit
- Created: 2024-09-23T06:41:03.000Z (4 months ago)
- Default Branch: main
- Last Pushed: 2024-10-31T10:53:45.000Z (3 months ago)
- Last Synced: 2024-12-20T09:08:54.594Z (about 1 month ago)
- Topics: ansible, django, gunicorn, linode, linode-api, linux, nginx, terraform, virtualization, yaml
- Language: Python
- Homepage: http://demo.mrmikenguyen.com/static/hello.html
- Size: 15.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## Django-ansible-demo (Work-in-progress)
### Check out site below. Still WIP!
```
demo.mrmikenguyen.com/static/hello.html
```TODO: Need to finish setting up Django.
**Steps that were done. Will cleanup and update later!**
1. Manually spin up Ubuntu server in Linode. (Plan on using Terraform to deploy infra)
2. SSH to server.
3. Create user under sudo group
4. useradd -m -s /bin/bash -G sudo mike
5. Change user password
6. passwd mike
7. Check if user was created
8. cat /etc/passwd
9. Switch to mike user
10. su mike
11. Change hostname through systemd
12. sudo hostnamectl set-hostname mike-systems
13. Reload shell
14. bash
15. In server for extra security and to auth by ssh without password auth "sudo vim /etc/ssh/sshd_config" change PermitRootLogin to "no", PubKeyAuthentication to "yes" and PasswordAuthentication to "no".
16. Copy Public IP address of server and create A record in Linode domains.
17. Install NGINX
18. sudo apt-get install nginx
19. (To Update Later). Domain purchased on cloudflare. Created A record with public IP of Linode host. Turned off proxy on CF.
20. Install Ansible on local machine. Created Ansible directory with 3 files hosts, deploy-demo.yml, and deploy.
21. To test: ansible-playbook deploy-demo.yml -i hosts -K
22.