Backup Jenkins to S3
Project description
jenkins-backup-s3
A collection of scripts to backup Jenkins configuration to S3, as well as manage and restore those backups. By default runs silently (no output) with proper exit codes. Log Level option enables output.
Setup
pip install jenkins-backup-s3
Configure S3 and IAM
-
Create an S3 bucket to store backups.
-
Create an IAM role with STS:AssumeRole and a trust Service ec2.amazonaws.com. The IAM role must have the
GetObject,CreateObject,DeleteObjectandListBucketS3 permissions for that bucket.
Usage
Setup with cron for ideal usage.
backup-jenkins {OPTIONS} {COMMAND} {COMMAND_OPTIONS}
Options can be set directly or via and environment variable.
The only required option is your S3 bucket:
backup-jenkins --bucket={BUCKET_NAME}
Other available options are:
Bucket prefix (defaults to "jenkins-backups"):
backup-jenkins --bucket-prefix={BUCKET_PREFIX}
Bucket region (defaults to "us-east-1"):
backup-jenkins --bucket-region={BUCKET_REGION}
Available commands:
createrestorelistdeleteprune
Run backup-jenkins {COMMAND} --help for command-specific options.
Running a daily backup on Jenkins
Create a new item in Jenkins and configure a build of this repository.
Set the shell / virtualenv builder (if you have it installed) to run backup-jenkins create.
Set the build on a daily CRON schedule.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file jenkins-backup-s3-0.1.8.tar.gz.
File metadata
- Download URL: jenkins-backup-s3-0.1.8.tar.gz
- Upload date:
- Size: 4.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.13.0 setuptools/40.2.0 requests-toolbelt/0.8.0 tqdm/4.23.1 CPython/2.7.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8a8b92f230fc7e5b6edc14573f88edbefbc61ecdc4049687e9085e61198463ba
|
|
| MD5 |
c6ededa4b91ba5369c21c5b024ffebe7
|
|
| BLAKE2b-256 |
aaa3b01473b1e265abe2a150b38b2ac5cd24a01cd95446932f06b86a00babcf8
|
File details
Details for the file jenkins_backup_s3-0.1.8-py2-none-any.whl.
File metadata
- Download URL: jenkins_backup_s3-0.1.8-py2-none-any.whl
- Upload date:
- Size: 5.3 kB
- Tags: Python 2
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.13.0 setuptools/40.2.0 requests-toolbelt/0.8.0 tqdm/4.23.1 CPython/2.7.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
df66d83f217909c51284d2d9f772aee8b4274e6879443f03a9393421270df525
|
|
| MD5 |
f85170ebe8f609ede2f72a6f0c427c28
|
|
| BLAKE2b-256 |
1a97ff43aa43d9ffaa4808cc8c22c3cd40d587bb5c792ebb435ce0457777b9a0
|