Skip to content

Commit 113ef08

Browse files
author
Petrov Kirill
committed
added example with 'endpoint' and 'retain'
1 parent e984513 commit 113ef08

File tree

1 file changed

+4
-14
lines changed

1 file changed

+4
-14
lines changed

README.md

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -25,19 +25,8 @@ docker run -d \
2525
--env MONGODB_PORT=27017 \
2626
--env MONGODB_USER=admin \
2727
--env MONGODB_PASS=password \
28-
chobostar/mongodb-backup-s3
29-
```
30-
31-
If you link `chobostar/mongodb-backup-s3` to a mongodb container with an alias named mongodb, this image will try to auto load the `host`, `port`, `user`, `pass` if possible. Like this:
32-
33-
```
34-
docker run -d \
35-
--env AWS_ACCESS_KEY_ID=myaccesskeyid \
36-
--env AWS_SECRET_ACCESS_KEY=mysecretaccesskey \
37-
--env BUCKET=mybucketname \
38-
--env BACKUP_FOLDER=a/sub/folder/path/ \
39-
--env INIT_BACKUP=true \
40-
--link my_mongo_db:mongodb \
28+
--env ENDPOINT_URL=https://s3.example.com
29+
--env RETAIN_COUNT=5
4130
chobostar/mongodb-backup-s3
4231
```
4332

@@ -51,7 +40,6 @@ docker run -d \
5140
--env BUCKET_REGION=mybucketregion \
5241
--env BACKUP_FOLDER=a/sub/folder/path/ \
5342
--env INIT_BACKUP=true \
54-
--link my_mongo_db:mongodb \
5543
chobostar/mongodb-backup-s3
5644
```
5745

@@ -68,6 +56,8 @@ mongodbbackup:
6856
- AWS_SECRET_ACCESS_KEY=mysecretaccesskey
6957
- BUCKET=my-s3-bucket
7058
- BACKUP_FOLDER=prod/db/
59+
- ENDPOINT_URL=https://s3.example.com
60+
- RETAIN_COUNT=5
7161
restart: always
7262
```
7363

0 commit comments

Comments
 (0)