All Projects → jasonheecs → ansible-digitalocean-sample-playbook

jasonheecs / ansible-digitalocean-sample-playbook

Licence: MIT License
A sample playbook that illustrates how to create and provision a DigitalOcean droplet with Ansible

Programming Languages

ruby
36898 projects - #4 most used programming language

Projects that are alternatives of or similar to ansible-digitalocean-sample-playbook

HacktoberFest-HelloWorld
All your PRs will be merged !! 😊
Stars: ✭ 24 (-45.45%)
Mutual labels:  digitalocean
kubeadm-ansible
Kuberadmin ansible is a toolkit for simple and quick installing k8s cluster.
Stars: ✭ 37 (-15.91%)
Mutual labels:  ansible-playbook
warp
WARP one-click script. Add an IPv4, IPv6 or dual-stack CloudFlare WARP network interface and Socks5 proxy for VPS. 一键脚本
Stars: ✭ 950 (+2059.09%)
Mutual labels:  digitalocean
DSA
Write DSA Codes into it
Stars: ✭ 18 (-59.09%)
Mutual labels:  digitalocean
glob-tool
A tool to test globs against sets of test strings quickly and easily for the DigitalOcean Community.
Stars: ✭ 14 (-68.18%)
Mutual labels:  digitalocean
ansible qa playbook
A simple ansible playbook to configure Dev and QA machine
Stars: ✭ 21 (-52.27%)
Mutual labels:  ansible-playbook
LaraSible
A complete ansible playbook for create a hosting envorinment with Nginx, PHP-FPM, Redis and MariaDB for Laravel Framework on Linux
Stars: ✭ 15 (-65.91%)
Mutual labels:  ansible-playbook
DigitalOcean.API
🐋 .NET implementation of the DigitalOcean API
Stars: ✭ 105 (+138.64%)
Mutual labels:  digitalocean
scalr
Autoscaling for Clouds
Stars: ✭ 17 (-61.36%)
Mutual labels:  digitalocean
Code-Hub
No description or website provided.
Stars: ✭ 107 (+143.18%)
Mutual labels:  digitalocean
ddns
a multiple providers ddns script without dependencies
Stars: ✭ 47 (+6.82%)
Mutual labels:  digitalocean
Hacktoberfest-Flutter
For all the Flutter developers out there make your first Pull Request and earn a free Tee from GitHub!
Stars: ✭ 89 (+102.27%)
Mutual labels:  digitalocean
HacktoberFest 2021
Hacktoberfest 2021 contribution repository✨
Stars: ✭ 43 (-2.27%)
Mutual labels:  digitalocean
digitalocean
A prototype API for Digital Ocean.
Stars: ✭ 35 (-20.45%)
Mutual labels:  digitalocean
Microservices-Nodejs-React
Applying Microservices Architecture using nodejs, MongoDB, redis, and handling async communication using nats. Deploying all these in a kubernetes cluster hosted on gcp.
Stars: ✭ 18 (-59.09%)
Mutual labels:  digitalocean
kubernetes-branch-review
🚟 Review clusters of GitHub pull requests / Examen des groupes de demandes de tirage de GitHub
Stars: ✭ 22 (-50%)
Mutual labels:  digitalocean
space-voyager
Interactive Space App . Attention Contributers! join discord server for discussion of Issues, Pull requests https://discord.gg/FpEK9AqbCf
Stars: ✭ 18 (-59.09%)
Mutual labels:  digitalocean
Github-Profile-README
A list of GitHub Readme Profiles.
Stars: ✭ 15 (-65.91%)
Mutual labels:  digitalocean
BhimIntegers
BhimIntegers🚀 is a C++ library that is useful when we are dealing with BigIntegers💥💥. We can handle big integers (integers having a size bigger than the long long int data type) and we can perform arithmetic operations📘 like addition, multiplication, subtraction, division, equality check, etc📐📐. Also, there are several functions like factorial, …
Stars: ✭ 43 (-2.27%)
Mutual labels:  digitalocean
speedtest-for-digitalocean
Run speed tests for all DigitalOcean datacenters faster than ever.
Stars: ✭ 40 (-9.09%)
Mutual labels:  digitalocean

Sample Ansible Playbook to provision a DigitalOcean droplet

Build Status

This is a sample playbook that illustrates how to create and provision a DigitalOcean droplet with Ansible; you can spin up and provision a droplet using the command line via this playbook.

Playbook Demo Image

This playbook does the following:

  • Spins up a DigitalOcean droplet
  • Adds the droplet's IP address to the ansible inventory file
  • Setup the swap file
  • Installs and setup fail2ban
  • Setup Uncomplicated firewall
  • Setup the timezone
  • Adds a new user account with sudo access
  • Adds a public ssh key for the new user account
  • Disables password authentication to the droplet
  • Deny root login to the droplet
  • Installs the UnattendedUpgrades package for automatic security updates
  • (Optional) Installs the LEMP stack
  • (Optional) Installs Docker

Prerequisites

Ansible >= 2.4.0.0

Usage

  1. Clone this repo:
git clone https://github.com/jasonheecs/ansible-digitalocean-sample-playbooks.git
cd ansible-digitalocean-sample-playbooks
  1. Rename the group_vars/all/secret.yml.example file to group_vars/all/secret.yml and change the secret variables to your appropriate values.

  2. Modify the values in group_vars/all/main.yml with your desired values.

  3. Run the following:

ansible-galaxy install -r requirements.yml
ansible-playbook -i hosts main.yml

Testing

Testing is done via Kitchen CI and Kitchen Ansible. Testing of the droplet setup is done via Kitchen Vagrant:

gem install bundler
bundle install
bundle exec kitchen test

Testing of the LEMP stack and Docker installation / setup is done via Kitchen Docker:

gem install bundler
bundle install
KITCHEN_YAML=".kitchen.travis.yml" bundle exec kitchen test

Refer to the travis.yml file and Travis build logs for details on the test build process and expected outputs.

License

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].