Sha256: 8811eb34c87d27de57a4af70f6ec02ce9bae68f9cb56d9c268bc532170b7aa87

Contents?: true

Size: 1.43 KB

Versions: 24

Compression:

Stored size: 1.43 KB

Contents

---
- name: create nginx config for rails app
  template:
    src: nginx-project
    dest: /etc/nginx/sites-available/{{project_name}}
  become: true

- name: Enable the non-ssl app
  file:
    src: /etc/nginx/sites-available/{{project_name}}
    dest: /etc/nginx/sites-enabled/{{project_name}}
    state: link
  when: ssl_enabled != true or nginx_ssl_config is not defined
  become: true

- name: Disable the non-ssl app
  file:
    dest: /etc/nginx/sites-enabled/{{project_name}}
    state: absent
  when: (ssl_enabled and nginx_ssl_config is defined)
  become: true

- name: create ssl nginx config for rails app
  template:
    src: nginx-project-ssl
    dest: /etc/nginx/sites-available/{{project_name}}-ssl
  when: (ssl_enabled and nginx_ssl_config is defined)
  become: true

- name: Enable SSL configured app
  file:
    src: /etc/nginx/sites-available/{{project_name}}-ssl
    dest: /etc/nginx/sites-enabled/{{project_name}}-ssl
    state: link
  when: (ssl_enabled and nginx_ssl_config is defined)
  become: true

- name: Disable SSL configured app
  file:
    dest: /etc/nginx/sites-enabled/{{project_name}}-ssl
    state: absent
  when: ssl_enabled != true or nginx_ssl_config is not defined
  become: true

- name: Enable a default server if one is not defined in the app
  template:
    src: 'default_server'
    dest: /etc/nginx/sites-enabled/default_server
    mode: 0644
    group: root
    owner: root
  become: true
  when: not default_server

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
subspace-3.0.13 ansible/roles/nginx-rails/tasks/main.yml
subspace-3.0.12 ansible/roles/nginx-rails/tasks/main.yml
subspace-3.0.11 ansible/roles/nginx-rails/tasks/main.yml
subspace-3.0.10 ansible/roles/nginx-rails/tasks/main.yml
subspace-3.0.9 ansible/roles/nginx-rails/tasks/main.yml
subspace-3.0.6 ansible/roles/nginx-rails/tasks/main.yml
subspace-3.0.5 ansible/roles/nginx-rails/tasks/main.yml
subspace-3.0.4 ansible/roles/nginx-rails/tasks/main.yml
subspace-3.0.3 ansible/roles/nginx-rails/tasks/main.yml
subspace-3.0.2 ansible/roles/nginx-rails/tasks/main.yml
subspace-3.0.0 ansible/roles/nginx-rails/tasks/main.yml
subspace-2.5.10 ansible/roles/nginx-rails/tasks/main.yml
subspace-3.0.0.rc1 ansible/roles/nginx-rails/tasks/main.yml
subspace-2.5.9 ansible/roles/nginx-rails/tasks/main.yml
subspace-2.5.8 ansible/roles/nginx-rails/tasks/main.yml
subspace-2.5.7 ansible/roles/nginx-rails/tasks/main.yml
subspace-2.5.6 ansible/roles/nginx-rails/tasks/main.yml
subspace-2.5.5 ansible/roles/nginx-rails/tasks/main.yml
subspace-2.5.4 ansible/roles/nginx-rails/tasks/main.yml
subspace-2.5.3 ansible/roles/nginx-rails/tasks/main.yml