https://github.com/skorupcia/digitalocean_docker_nginx
Digitalocean Docker container with NGINX
https://github.com/skorupcia/digitalocean_docker_nginx
ansible digitalocean docker nginx
Last synced: 2 months ago
JSON representation
Digitalocean Docker container with NGINX
- Host: GitHub
- URL: https://github.com/skorupcia/digitalocean_docker_nginx
- Owner: skorupcia
- Created: 2024-04-09T16:54:48.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-04-09T17:20:27.000Z (about 2 years ago)
- Last Synced: 2025-03-30T23:13:34.292Z (over 1 year ago)
- Topics: ansible, digitalocean, docker, nginx
- Language: Python
- Homepage:
- Size: 14.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Digitalocean Docker container with NGINX
[](https://github.com/skorupcia/DigitalOcean_Docker_NGINX/actions/workflows/ci.yml)
macOS: 14.4.1
Ubuntu: 20-04-x64
Docker: 25.0.3
## Instructions
1. Add your machine SSH to DigitalOcean account
2. Update ssh_key variable in provision.yml with your ssh fingerprint
3. Create API token and add to your DigitalOcean project
4. Export your API token:
export DO_API_TOKEN=YOUR_API_TOKEN_HERE
5. Run provision.yml playbook to deploy new droplet on DigtalOcean and automatically add ip dinamically to hosts.
ansible-playbook provision.yml
6. Run main.yml to install Docker and create NGINX container
ansible-playbook main.yml
7. Enjoy!
## Droplet Delete
If you would like to delete droplet, simply switch state of "Create Digitalocean droplet" from PRESENT to ABSENT and run playbook.
## Useful Links
[community.digitalocean](https://github.com/ansible-collections/community.digitalocean/tree/main)
[Dynamic-Inventory](https://github.com/geerlingguy/ansible-for-devops/tree/master/dynamic-inventory/digitalocean)
[NGINX](https://www.nginx.com/)