Download the PHP package nickpoulos/ez-rider without Composer
On this page you can find all versions of the php package nickpoulos/ez-rider. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download nickpoulos/ez-rider
More information about nickpoulos/ez-rider
Files in nickpoulos/ez-rider
Package ez-rider
Short Description Ez-Rider: Easily generate Docker Compose Override files with secrets
License MIT
Homepage https://nickpoulos.info
Informations about the package ez-rider
EzRider is a php-cli command (packaged as a PHAR) that provides an easy way to generate Docker Compose Override files for your applications.
Many times your application may require secrets or other sensitive information, perhaps even randomly generated data. By including certain annotations in your Docker Compose files, Ez-Rider will fetch/generate this data, and write the proper override file automatically.
You can think of this as akin to Vault annotations in K8s/Helm, which was an inspiration for this package and its annotation syntax.
Created and maintained by Nick Poulos
Development
- Built using Laravel Zero - a great little distro of Laravel for building and packaging PHP-CLI applications using our favorite PHP framework
- Includes plugins for HashiCorp Vault, Laravel Application Keys, RSA Key-Pairs, and some random data generators.
- Easily create new plugins, please submit a PR!
Requirements
- PHP 8.0+ installed on your system: Install Instructions
- Make sure YAML PECL Extension is also installed:
brew install libyaml && pecl install yaml
- Install Composer globally:
brew install composer
- Ensure Composer's bin folder is in your $PATH:
export PATH=$PATH:$HOME/.composer/vendor/bin
Quick Start
-
Install this package globally via Composer, NOT from within your project source
- In your project's Docker Compose file, create a service containing an environment variable using the syntax below:
docker-compose.yml
- In your project's root folder (or wherever docker-compose.yml is located), run:
This command accepts an optional config file argument. This is useful when multiple mappings or customized docker-compose.yml filenames are required.
The default config below will be used when no config file argument is given.
-
The command will map the appropriate variables and generate your
docker-compose.overrides.yml
file. - The config file can be committed as part of source control with your repo, and contains a simple array of input/output mappings:
map
: array of map objects that sets which docker-compose files to map, and their output filename.
Vault Plugin
The HashiCorp Vault Plugin connects to Vault servers via API. It requires a Vault Base Url and Token to operate.
The plugin will prompt you for this info and is cached for subsequent calls.
If you have either of the following environment vars set, the prompt is skipped and these values used.
For example:
See the annotation syntax in Step 2 above.
Random Generator
The random generator provides a few ways to generate some random data in your Docker Compose file. There are methods for random string, random integer, and random element from array.
Laravel App Key Generator
This plugin will generate a Base64 encoded Laravel Application Key.
RSA Key/Pair Generator
This plugin generates an RSA key/pair, and is suitable for things like Laravel Passport keys and other use cases.
You can choose to use the public or private key, as well as provide arguments for key length and a "label" for the key/value pair. If you only have one key value pair in your env, the label argument is not needed. Key length is also optional and will default to 4096.
See the annotation syntax in Step 2 above.
License
EzRider is an open-source software licensed under the MIT license.
All versions of ez-rider with dependencies
ext-yaml Version *
composer/composer Version ^2.1
guzzlehttp/guzzle Version ^7.4
guzzlehttp/psr7 Version ^2.1
illuminate/http Version ^9.0
laminas/laminas-text Version ^2.8
laravel-zero/phar-updater Version ^1.0.6
phpseclib/phpseclib Version ~3.0
wilderborn/partyline Version ^1.0