diff options
Diffstat (limited to 'ansible/roles')
-rw-r--r-- | ansible/roles/nginx/.yamllint | 11 | ||||
-rw-r--r-- | ansible/roles/nginx/defaults/main.yml | 2 | ||||
-rw-r--r-- | ansible/roles/nginx/molecule/default/molecule.yml | 30 | ||||
-rw-r--r-- | ansible/roles/nginx/molecule/default/playbook.yml | 5 | ||||
-rw-r--r-- | ansible/roles/nginx/molecule/default/prepare.yml | 8 |
5 files changed, 55 insertions, 1 deletions
diff --git a/ansible/roles/nginx/.yamllint b/ansible/roles/nginx/.yamllint new file mode 100644 index 00000000..ad0be760 --- /dev/null +++ b/ansible/roles/nginx/.yamllint @@ -0,0 +1,11 @@ +extends: default + +rules: + braces: + max-spaces-inside: 1 + level: error + brackets: + max-spaces-inside: 1 + level: error + line-length: disable + truthy: disable diff --git a/ansible/roles/nginx/defaults/main.yml b/ansible/roles/nginx/defaults/main.yml index 260de9bf..8bf44197 100644 --- a/ansible/roles/nginx/defaults/main.yml +++ b/ansible/roles/nginx/defaults/main.yml @@ -4,7 +4,7 @@ simulated_hosts: http: nexus: all_simulated_hosts: - "{{ simulated_hosts.git + simulated_hosts.http + simulated_hosts.nexus }}" + "{{ simulated_hosts.git + simulated_hosts.http + simulated_hosts.nexus }}" nginx: ports: diff --git a/ansible/roles/nginx/molecule/default/molecule.yml b/ansible/roles/nginx/molecule/default/molecule.yml new file mode 100644 index 00000000..63c47724 --- /dev/null +++ b/ansible/roles/nginx/molecule/default/molecule.yml @@ -0,0 +1,30 @@ +--- +dependency: + name: galaxy +driver: + name: docker +lint: + name: yamllint +platforms: + - name: infrastructure-server + image: molecule-${PREBUILD_PLATFORM_DISTRO:-centos}:${PREBUILD_DISTRO_VERSION:-centos7.6} + pre_build_image: true + privileged: true + override_command: false + volumes: + - /var/lib/docker + groups: + - infrastructure +provisioner: + name: ansible + env: + ANSIBLE_ROLES_PATH: ../../../../test/roles + inventory: + links: + group_vars: ../../../../group_vars + lint: + name: ansible-lint +verifier: + name: testinfra + lint: + name: flake8 diff --git a/ansible/roles/nginx/molecule/default/playbook.yml b/ansible/roles/nginx/molecule/default/playbook.yml new file mode 100644 index 00000000..431bb666 --- /dev/null +++ b/ansible/roles/nginx/molecule/default/playbook.yml @@ -0,0 +1,5 @@ +--- +- name: Converge + hosts: all + roles: + - nginx diff --git a/ansible/roles/nginx/molecule/default/prepare.yml b/ansible/roles/nginx/molecule/default/prepare.yml new file mode 100644 index 00000000..5c6ff5d8 --- /dev/null +++ b/ansible/roles/nginx/molecule/default/prepare.yml @@ -0,0 +1,8 @@ +--- +- name: Prepare + hosts: all + vars_files: + - ../../../../roles/nginx/defaults/main.yml + roles: + - prepare-docker-dind + - prepare-nginx |