diff --git a/hosts b/hosts index c255b13..4fde8f5 100644 --- a/hosts +++ b/hosts @@ -1,2 +1,2 @@ [production] -cce-prod ansible_host=cce.ebookfoundation.org ansible_user=ubuntu \ No newline at end of file +cce_prod ansible_host=cce.ebookfoundation.org ansible_user=ubuntu \ No newline at end of file diff --git a/roles/cce_prod/tasks/main.yml b/roles/cce_prod/tasks/main.yml index 8e40e26..63c67d4 100644 --- a/roles/cce_prod/tasks/main.yml +++ b/roles/cce_prod/tasks/main.yml @@ -95,11 +95,9 @@ group: "{{ user_name }}" mode: 0755 - - # TODO: Enable Nginx -# TODO: Configure HTTPS cert w/ Certbot +# Configure HTTPS cert w/ Certbot - name: Generate HTTPS cert become: true - command: "certbot --nginx" \ No newline at end of file + command: "certbot --nginx" # Does this command halt for [y/n] input? \ No newline at end of file diff --git a/setup-prod.yml b/setup-prod.yml index eec0c59..89e5189 100644 --- a/setup-prod.yml +++ b/setup-prod.yml @@ -1 +1,17 @@ -an \ No newline at end of file +- hosts: cce_prod + tasks: + - name: Add python repository + become: true + apt_repository: repo='ppa:deadsnakes/ppa' state=present + - name: Install python3.7 and pip + become: true + apt: + name: "{{ item }}" + update: true + update_cache: true + with_items: + - 'python3.7' + - 'python3-pip' + + - include_role: + name: cce_prod \ No newline at end of file