-
-
Save aka99/346d3cae887cc2d0a0cbdca38a5f1c7d to your computer and use it in GitHub Desktop.
confluence backup script
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
#!/bin/sh | |
DATE=`date '+%y%m%d'` | |
cd /var/backup/atlassian-confluence | |
tar czf var-atlassian-$DATE.tar.gz /var/atlassian/ | |
tar czf opt-atlassian-$DATE.tar.gz /opt/atlassian/confluence/ | |
pg_dump -h localhost -U <user> <password> > confluence-$DATE.sql | |
gzip confluence-$DATE.sql | |
find /var/backup/atlassian-confluence/ -type f -mtime +30 -exec rm {} \; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment