Skip to content

Designed to automate the setup of Nginx and/or Apache2 web server configurations, integrate with PHP-FPM, and handle SSL certificate provisioning using Certbot.

License

Notifications You must be signed in to change notification settings

quockhanh291/ansible-web-stack

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ansible Web Server Provisioning

This project provides a flexible and modular Ansible playbook collection for efficiently deploying and managing web server stacks. It's designed to automate the setup of various web server configurations, integrate with PHP-FPM, and handle SSL certificate provisioning using Let's Encrypt.

✨ Features

  • Flexible Web Server Choices: Deploy with Nginx, Apache, or a combined Nginx+Apache setup (where Nginx acts as a reverse proxy).
  • PHP-FPM Integration: Seamlessly configures PHP-FPM for dynamic web application serving.
  • Automated SSL Certificates: Provisions and automatically renews SSL certificates from Let's Encrypt using Certbot.
  • Modular & Reusable Roles: Organized into dedicated Ansible roles for nginx, apache, php-fpm, and common webserver utilities, promoting maintainability.
  • Environment Management: Easily configure and manage different deployment environments (e.g., staging, production) via structured inventory files.

🚀 Quick Start

  1. Clone the Repository

  2. Configure Your Inventory: Edit the inventory files in the inventory/ directory (e.g., staging.yaml, host_vars/that_server.yaml, group_vars/webservers.yaml) to define your target servers, domain names, preferred web_server type, and other variables.

  3. Run the Playbook:

    Execute the main playbook, specifying your inventory file:

    ansible-playbook -i inventory/staging.yaml playbooks/site.yaml --ask-become-pass

    (The --ask-become-pass flag will prompt for the sudo password on your target server.)

About

Designed to automate the setup of Nginx and/or Apache2 web server configurations, integrate with PHP-FPM, and handle SSL certificate provisioning using Certbot.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages