nginx installation role
Go to file
2023-01-30 15:44:15 +01:00
.githooks Add regular schedule 2021-03-24 14:03:53 +01:00
.github/workflows Add regular schedule 2021-03-24 14:03:53 +01:00
defaults Remove unnecessary variables 2021-03-25 11:22:10 +01:00
handlers Add firewalld handler 2021-03-24 16:24:20 +01:00
meta Revive the role 2022-06-27 13:33:40 +02:00
molecule/default Add bookworm 2023-01-30 15:39:10 +01:00
tasks Revive the role 2022-06-27 13:33:40 +02:00
templates Revive the role 2022-06-27 13:33:40 +02:00
vars Revive the role 2022-06-27 13:33:40 +02:00
.gitignore first commit 2021-03-24 09:46:11 +01:00
.yamllint Add yamllint 2021-03-25 14:09:43 +01:00
README.md Tidy README 2022-06-27 16:10:59 +02:00

Test deployment

geekoops-nginx

Configurable ansible role for setting up a nginx webserver on a Linux server. Works with

  • openSUSE Leap 15.3
  • openSUSE Leap 15.4
  • Debian Buster

Role Variables


You can set the following variables to configure the role. Here listed are the variables and their default settings.

Firewall configuration (disable by default)

Value Description Default
config_firewall Enable firewall configuration false
firewall_zone Firewall zone to configure "public"
open_http Open http port true
open_https Open https port true
setup_default_page Setup a default page false
default_page_hostname Hostname for the default page "localhost"

Example Playbook

Including an example of how to use your role (for instance, with variables passed in as parameters) is always nice for users too:

- hosts: jellyfish
  roles:
     - { role: geekoops-nginx, config_firewall: true }

An advanced example for the imaginary jellyfish test server

- hosts: jellyfish
  roles:
     - role: geekoops-nginx
       vars:
         setup_default_page: true
         default_page_hostname: "{{ansible_host}}"
         config_firewall: true
         firewall_zone: "public"

License

MIT

Development

Add githooks

This repository ships pre-commit git hooks that will check the yaml syntax. To configure them do

git config --local core.hooksPath .githooks/