Skip to content

AndrewGodGivens/ansible_walg

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ageres210784.ansible_walg

Role for wal-g installation and configuration.

Requirements

Ansible Galaxy

Role Variables

You can see all vars in default/main.yml vars file.

To restore by a certain time you should use the tag of "restore" and the following variables:

postgresql_conf_recovery:
  - recovery_target_action='promote'
  - recovery_target_time='2021-07-15 11:35:04'
  - recovery_target_timeline='current'
walg_restore_name: base_0000000300000000000000DA

Postgres in docker

If you use postgresql in docker you should install wal-g in a docker container and configuring it with environment variables. In this case this role configure crontab for periodic archiving.

Config:

walg_in_docker: true
walg_cron_time:
  minute: "*"
  hour: "*"
walg_pgdata: "/var/lib/postgresql/data"
walg_cron_user: "root"

Run:

ansible-playbook -t crontab run-walg.yml

Dependencies

None

Tested with Ansible

2.9

Example Playbook

- hosts: servers
  roles:
    - role: ageres210784.ansible_walg

License

Apache 2.0

Author Information

Evseev Sergey

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Jinja 100.0%