Skip to main content

Tools for working with vy

Project description

vytools: Tools for distributed continuous integration

Installation and Setup

pip install vytools

or often

pip3 install vytools

To take advantage of autocompletion add the following to your ~/.bashrc file

eval "$(register-python-argcomplete vytools)"

Configuration

vytools searches a set of directories for specialized "vy" components. These directories comprise the vy "context" which must be specified before vy can be used. In addition a "jobs" directory will need to be specified. You can also configure "secrets".

CONTEXT PATHS [required configuration]

Point to directories (comma or semi-colon delimited) which contain the vy components with command line:

vytools --contexts "/some/path/to/contexts/dir,/path/to/another/contexts/dir"

Or in a python script

import vytools
vytools.CONFIG.set('contexts',['/some/path/to/contexts/dir','/path/to/another/contexts/dir'])

SECRETS [optional configuration]

Set a secret id (e.g. SECRETA and SECRETB) or private ssh key (e.g. MYSSHKEY) and point to files containing the docker build secrets associated with those ids or private ssh keys with command line:

vytools --secret SECRETA="/some/path/to/secrets/dir/secreta.txt" --secret SECRETB="/path/to/anothersecret" --ssh MYSSHKEY=/home/user/.ssh/mysecretkey

Or in a python script

import vytools
vytools.CONFIG.set('secrets',{'SECRETA':'/some/path/to/secrets/dir/secreta.txt','SECRETB':'/path/to/anothersecret'})
vytools.CONFIG.set('ssh',{'MYSSHKEY':'/home/user/.ssh/myprivatekey'})

The secret files can be used with docker build secrets. For example the above secrets could be used as follows without exposing the secret in the build cache:

RUN --mount=type=secret,id=SECRETA wget --header="Authorization: Bearer $(cat /run/secrets/SECRETA)" https://some_url/some_artifact.tar.gz
RUN --mount=type=ssh,id=MYSSHKEY git clone git@github.com:username/repo.git

Project details


Download files

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

Source Distribution

vytools-0.7.0.tar.gz (34.3 kB view hashes)

Uploaded Source

Built Distribution

vytools-0.7.0-py3-none-any.whl (39.9 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page