File tree Expand file tree Collapse file tree 1 file changed +9
-13
lines changed Expand file tree Collapse file tree 1 file changed +9
-13
lines changed Original file line number Diff line number Diff line change 14
14
15
15
## Prerequisites
16
16
17
- - Docker
18
- - Docker Compose
17
+ - bash and sudo privilege
19
18
- AWS S3 bucket and credentials
19
+ - Rest will be installed at the runtime
20
20
21
21
## Installation
22
22
45
45
3. ** Build and Run the Docker Container:**
46
46
47
47
` ` ` bash
48
- sudo ./init.sh /path/to/backup/volume
48
+ chmod +x ./xbackup.sh
49
+ sudo ./xbackup.sh start
49
50
` ` `
50
51
51
- # # Usage
52
-
53
- The ` init.sh` script sets up Docker, installs necessary packages, and configures the backup environment. It will:
54
-
55
- 1. Install Docker if it' s not already installed.
56
- 2. Configure the Docker repository and install Docker CE.
57
- 3. Start and enable the Docker service.
58
- 4. Launch the Docker Compose setup for `xbackup`.
59
-
60
52
# ## Backup Scheduling
61
53
62
54
Backups are managed using cron jobs defined in the ` docker-compose.yml` file. Modify the cron job schedule as needed:
@@ -72,7 +64,11 @@ CRON_TIME="0 */3 * * *"
72
64
To restore a backup, download the backup files from S3 and use ` xtrabackup` to apply logs and restore the database:
73
65
74
66
` ` ` bash
75
- sudo docker exec xbackup /usr/local/bin/prepare.sh
67
+ ./xbackup.sh load # it'll download the backup from s3
68
+ # check everything is correct and correctly downloaded/decompressed
69
+
70
+ # move the backup into the data dir
71
+ ./xbackup.sh apply
76
72
` ` `
77
73
78
74
# # Contributing
You can’t perform that action at this time.
0 commit comments