Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

Encrypt passwords for use with Travis CI.

Project Description

Travis Encrypt is a Python command line application that provides an easy way to encrypt passwords and environment variables for use with Travis CI. All passwords and environment variables are encrypted with the PKCS1v15 padding scheme as it’s the only padding supported by Travis CI.

Installation

To install Travis Encrypt simply run the following command in a terminal window:

$  pip install travis-encrypt

If you would rather install from source, run the following commands in a terminal window:

$  git clone https://github.com/mandeep/Travis-Encrypt.git
$  cd Travis-Encrypt
$  python setup.py install

Travis Encrypt will attempt to install the cryptography package, however the package requires development packages for C and Python. If installation fails, please see the cryptography installation guide: https://cryptography.io/en/latest/installation/

Usage

With Travis Encrypt installed, the command line application can be invoked with the following command and arguments:

usage: travis-encrypt [options] github_username repository [path]

positional arguments:
    github_username         GitHub username that houses the repository
    repository              Name of the repository whose password requires encryption
    path                    Path to the repository's .travis.yml file

optional arguments:
    --help                  Show the help message and quit
    --deploy                Encrypt a password for continuous deployment usage
    --env                   Encrypt an environment variable

When the command is entered, the application will issue a prompt where the user can enter either a password or environment variable. In both cases, the prompt will print ‘Password:’. Once the prompt is answered, Travis Encrypt will print the encrypted password to standard output. If a path to .travis.yml is provided the encrypted password will be written to .travis.yml instead of printing to standard output.

Example of password encryption (the password is hidden when entering):

$  travis-encrypt mandeep Travis-Encrypt
Password:
Please add the following to your .travis.yml:

secure: "oxTYla2fHNRRjD0akv1e..." (edited for brevity)

Example of deployment password encryption:

$  travis-encrypt --deploy mandeep Travis-Encrypt /home/user/.travis.yml
Password:
Encrypted password added to /home/user/.travis.yml

Example of encrypting the environment variable API_TOKEN=”abc123”:

$  travis-encrypt --env mandeep Travis-Encrypt /home/user/.travis.yml
Password:
Encrypted password added to /home/user/.travis.yml
Release History

Release History

This version
History Node

0.9.0

History Node

0.8.0

History Node

0.7.5

History Node

0.7.3

History Node

0.7.2

History Node

0.7.1

History Node

0.7.0

History Node

0.6.0

History Node

0.5.6

History Node

0.5.5

History Node

0.5.4

History Node

0.5.3

History Node

0.5.2

History Node

0.5.1

History Node

0.5.0

History Node

0.4.9

History Node

0.4.8

History Node

0.4.7

History Node

0.4.6

History Node

0.4.5

History Node

0.4.4

History Node

0.4.3

History Node

0.4.2

History Node

0.4.1

History Node

0.4.0

History Node

0.3.4

History Node

0.3.3

History Node

0.3.2

History Node

0.3.1

History Node

0.3.0

History Node

0.2.0

History Node

0.1.1

History Node

0.1.0

History Node

0.0.1

Download Files

Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
travis_encrypt-0.9.0-py2-none-any.whl (20.2 kB) Copy SHA256 Checksum SHA256 py2 Wheel Sep 8, 2017
travis_encrypt-0.9.0-py3-none-any.whl (20.2 kB) Copy SHA256 Checksum SHA256 py3 Wheel Sep 8, 2017
travis-encrypt-0.9.0.tar.gz (17.3 kB) Copy SHA256 Checksum SHA256 Source Sep 8, 2017

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting