ajgarlag.rollback

ajgarlag.rollback

Ansible role to rollback applications heavily inspired by ansistrano.

Role Variables

  • ajgarlag_rollback_path: Path where the code has been deployed to (defaults to {{ansible_env.HOME}}/project).

Role hooks

You can hook your own tasks files to the rollback process defining any of the following vars:

  • ajgarlag_rollback_before_setup_tasks_file
  • ajgarlag_rollback_after_setup_tasks_file
  • ajgarlag_rollback_before_symlink_tasks_file
  • ajgarlag_rollback_after_symlink_tasks_file
  • ajgarlag_rollback_before_cleanup_tasks_file
  • ajgarlag_rollback_after_cleanup_tasks_file

To do it, you must define the desired var with the path to the tasks file:

ajgarlag_rollback_after_symlink_tasks_file: "{{ playbook_dir }}/tasks/after_symlink.yml"

Example Playbook

- hosts: all
  vars:
    ajgarlag_rollback_path: /var/www/application
  roles:
    - role: ajgarlag.rollback

License

MIT

Author Information

Developed with ♥ by Antonio J. García Lagar.

About

Ansible role to rollback applications heavily inspired by ansistrano

Install
ansible-galaxy install ajgarlag.rollback
GitHub repository
License
mit
Downloads
97
Owner
I solve problems!