Last active
August 29, 2015 14:12
-
-
Save sameg14/bbf762e47da1df85ff52 to your computer and use it in GitHub Desktop.
Platform QA Deploy - Ansible Playbook
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
- hosts : platform-qa-server | |
su : yes | |
vars : | |
hipchat_rooms: | |
- { token: "a2a1d9143d45feac80d33bf5246247", room: "504774", name: "LIN Digital Engineering" } | |
pre_tasks: | |
- name : HipChat - Attempting Deploy... | |
hipchat: token={{ item.token }} room={{ item.room }} msg="Deploying platform to QA" notify=yes | |
with_items: hipchat_rooms | |
run_once: yes | |
changed_when: false | |
tasks : | |
- name : Checkout qa branch | |
su_user : fmpub | |
git : repo=ssh://[email protected]/rmm/platform.git | |
dest=/home/fmpub/platform | |
version=qa | |
- name : Update composer | |
shell : cd /home/fmpub/platform; composer update | |
- name : Clear cache | |
shell : rm -rf /home/fmpub/platform/cache/* | |
- name : Restart apache | |
service: name=httpd state=restarted | |
post_tasks: | |
- name : HipChat - Finished Deploy... | |
hipchat: token={{ item.token }} room={{ item.room }} msg="Successfully Deployed platform to QA" notify=yes | |
with_items: hipchat_rooms | |
run_once: yes | |
changed_when: false |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment