Docker Image for MySQL AWS S3 backups based on Alpine Linux, mysql and awscli
Designed to be executed from EC2 instance that has IAM role assigned to communicate with backup S3 bucket.
MYSQL_USER
- MySQL userMYSQL_PASS
- MySQL passwordMYSQL_HOST
- MySQL hostMYSQL_PORT
- MySQL portMYSQL_DB_NAME
- MySQL database name to dumpS3_BUCKET
- S3 bucket name where backups will be stored (can also contain subpath, e.g.:bucket/sub-folder
)
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "Stmt1412000000001",
"Effect": "Allow",
"Action": [
"s3:ListBucket"
],
"Resource": [
"arn:aws:s3:::BUCKET_NAME"
]
},
{
"Sid": "Stmt1412000000002",
"Effect": "Allow",
"Action": [
"s3:PutObject",
"s3:PutObjectAcl"
],
"Resource": [
"arn:aws:s3:::BUCKET_NAME/*"
]
}
]
}