From e39f2597a836ca4c778e27b9d3d88064f07d4ea6 Mon Sep 17 00:00:00 2001 From: Jacob Cody Wimer Date: Thu, 4 Feb 2016 10:59:56 -0500 Subject: [PATCH] Code deploy is working --- playbooks/code-deploy.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/playbooks/code-deploy.yml b/playbooks/code-deploy.yml index 1dda536..a49f6ff 100644 --- a/playbooks/code-deploy.yml +++ b/playbooks/code-deploy.yml @@ -14,7 +14,7 @@ command: chdir=/root/wrestlingApp docker build -t wrestlingdev-web -f rails-prod-Dockerfile . - name: Kill running docker container - command: docker kill wrestlingdev-web + shell: docker stop $(docker ps -a -q) - name: Start docker container command: docker run -h {{ansible_hostname}} -d --restart=always --env-file /root/prod.env -v /srv/docker/apache2/logs:/var/log/apache2 -v /etc/localtime:/etc/localtime -p 80:80 -p 443:443 wrestlingdev-web @@ -28,10 +28,10 @@ command: chdir=/root/wrestlingApp git pull origin master - name: Create apache docker image - command: chdir=/root/wrestlingApp docker build -t wrestlingdev-web -f rails-prod-Dockerfile . + command: chdir=/root/wrestlingApp docker build -t wrestlingdev-worker -f rails-prod-Dockerfile . - name: Kill running docker container - command: docker kill wrestlingdev-web + shell: docker stop $(docker ps -a -q) - name: Start docker container command: docker run -h {{ansible_hostname}} -d --restart=always --env-file /root/prod.env -v /etc/localtime:/etc/localtime wrestlingdev-worker bundle exec rake jobs:work RAILS_ENV=production