Moved prod.env file

This commit is contained in:
2016-02-03 11:20:47 -05:00
parent 37adf2e65b
commit 2098efe716
3 changed files with 19 additions and 19 deletions

View File

@@ -3,48 +3,48 @@
# #
- name: Create prod.env - name: Create prod.env
shell: touch /var/www/html/prod.env shell: touch /root/prod.env
- name: Declare env file - name: Declare env file
shell: echo export WRESTLINGDEV_ENV_FILE=/var/www/html/prod.env shell: echo export WRESTLINGDEV_ENV_FILE=/root/prod.env
- name: Set env file permanently - name: Set env file permanently
shell: echo export WRESTLINGDEV_ENV_FILE=/var/www/html/prod.env >> /etc/environment shell: echo export WRESTLINGDEV_ENV_FILE=/root/prod.env >> /etc/environment
- name: Set DB Name - name: Set DB Name
shell: echo export WRESTLINGDEV_DB_NAME={{ lookup('env', 'WRESTLINGDEV_DB_NAME') }} >> /var/www/html/prod.env shell: echo export WRESTLINGDEV_DB_NAME={{ lookup('env', 'WRESTLINGDEV_DB_NAME') }} >> /root/prod.env
- name: Set db password - name: Set db password
shell: echo export WRESTLINGDEV_DB_PWD={{ lookup('env', 'WRESTLINGDEV_DB_PWD') }} >> /var/www/html/prod.env shell: echo export WRESTLINGDEV_DB_PWD={{ lookup('env', 'WRESTLINGDEV_DB_PWD') }} >> /root/prod.env
- name: Set db username - name: Set db username
shell: echo export WRESTLINGDEV_DB_USR={{ lookup('env', 'WRESTLINGDEV_DB_USR') }} >> /var/www/html/prod.env shell: echo export WRESTLINGDEV_DB_USR={{ lookup('env', 'WRESTLINGDEV_DB_USR') }} >> /root/prod.env
- name: Set db host - name: Set db host
shell: echo export WRESTLINGDEV_DB_HOST={{ lookup('env', 'WRESTLINGDEV_DB_HOST') }} >> /var/www/html/prod.env shell: echo export WRESTLINGDEV_DB_HOST={{ lookup('env', 'WRESTLINGDEV_DB_HOST') }} >> /root/prod.env
- name: Set db port - name: Set db port
shell: echo export WRESTLINGDEV_DB_PORT={{ lookup('env', 'WRESTLINGDEV_DB_PORT') }} >> /var/www/html/prod.env shell: echo export WRESTLINGDEV_DB_PORT={{ lookup('env', 'WRESTLINGDEV_DB_PORT') }} >> /root/prod.env
- name: Set devise secret key - name: Set devise secret key
shell: echo export WRESTLINGDEV_DEVISE_SECRET_KEY={{ lookup('env', 'WRESTLINGDEV_DEVISE_SECRET_KEY') }} >> /var/www/html/prod.env shell: echo export WRESTLINGDEV_DEVISE_SECRET_KEY={{ lookup('env', 'WRESTLINGDEV_DEVISE_SECRET_KEY') }} >> /root/prod.env
- name: Set secret key base - name: Set secret key base
shell: echo export WRESTLINGDEV_SECRET_KEY_BASE={{ lookup('env', 'WRESTLINGDEV_SECRET_KEY_BASE') }} >> /var/www/html/prod.env shell: echo export WRESTLINGDEV_SECRET_KEY_BASE={{ lookup('env', 'WRESTLINGDEV_SECRET_KEY_BASE') }} >> /root/prod.env
- name: Set new relic license - name: Set new relic license
shell: echo export WRESTLINGDEV_NEW_RELIC_LICENSE_KEY={{ lookup('env', 'WRESTLINGDEV_NEW_RELIC_LICENSE_KEY') }} >> /var/www/html/prod.env shell: echo export WRESTLINGDEV_NEW_RELIC_LICENSE_KEY={{ lookup('env', 'WRESTLINGDEV_NEW_RELIC_LICENSE_KEY') }} >> /root/prod.env
- name: Set memcached username - name: Set memcached username
shell: echo export MEMCACHIER_USERNAME={{ lookup('env', 'MEMCACHIER_USERNAME') }} >> /var/www/html/prod.env shell: echo export MEMCACHIER_USERNAME={{ lookup('env', 'MEMCACHIER_USERNAME') }} >> /root/prod.env
- name: Set memcached password - name: Set memcached password
shell: echo export MEMCACHIER_PASSWORD={{ lookup('env', 'MEMCACHIER_PASSWORD') }} >> /var/www/html/prod.env shell: echo export MEMCACHIER_PASSWORD={{ lookup('env', 'MEMCACHIER_PASSWORD') }} >> /root/prod.env
- name: Set memcached servers - name: Set memcached servers
shell: echo export MEMCACHIER_SERVERS={{ lookup('env', 'MEMCACHIER_SERVERS') }} >> /var/www/html/prod.env shell: echo export MEMCACHIER_SERVERS={{ lookup('env', 'MEMCACHIER_SERVERS') }} >> /root/prod.env
- name: Set email password - name: Set email password
shell: echo export WRESTLINGDEV_EMAIL_PWD={{ lookup('env', 'WRESTLINGDEV_EMAIL_PWD') }} >> /var/www/html/prod.env shell: echo export WRESTLINGDEV_EMAIL_PWD={{ lookup('env', 'WRESTLINGDEV_EMAIL_PWD') }} >> /root/prod.env

View File

@@ -2,8 +2,8 @@
# This task clones the repo and runs the webserver docker container. # This task clones the repo and runs the webserver docker container.
- name: Copy the code from repository - name: Copy the code from repository
git: repo={{ repository }} dest=/var/www/html/ git: repo={{ repository }} dest=/root/wrestlingApp
- name: Create and start apache docker image - name: Create and start apache docker image
shell: cd /var/www/html/ && bash rails-prod.sh wrestlingdev-web shell: cd /root/wrestlingApp && bash rails-prod.sh wrestlingdev-web

View File

@@ -2,7 +2,7 @@
# This task clones the repo and runs the worker docker container. # This task clones the repo and runs the worker docker container.
# #
- name: Copy the code from repository - name: Copy the code from repository
git: repo={{ repository }} dest=/var/www/html/ git: repo={{ repository }} dest=/root/wrestlingApp
- name: Create and run delayed job worker - name: Create and run delayed job worker
shell: cd /var/www/html/ && bash rails-worker-prod.sh wrestlingdev-worker shell: cd /root/wrestlingApp && bash rails-worker-prod.sh wrestlingdev-worker