ddsl
Docker Declarative Specific Language
ddsl allow developers to express in a declarative way how application are built, run and tested. Building, running and testing applications should be semlessly, independently on what environment your are. ddsl makes the latter easy by providing one cli to use in CI and development environments.
Dependencies
- ruby
- docker
- docker-compose
Installation
You can install ddsl with either of this mechansims
Gem
Like any ruby gem
gem install ddsl
Docker
When running on modern CI providers like Circle CI or GitLab you can install it using the docker image bilby91/ddsl:latest. You can find more information on how to use it by looking at ddsl's Circle CI implementation or GitLab implementation
Usage
ddsl it's a command line tool that works with a companion .ddsl.yml file. In the .ddsl.yml file you can declare the diferent builds and runs that your application will need. A very simple example would look like this:
version: 1
builds:
- name: feature-branch
type: docker
context: .
file: docker/Dockerfile
tags:
- bilby91/ddsl:$CI_SHA1
push: true
cache_from:
- bilby91/ddsl:latest
runs:
- name: test
type: docker
image: bilby91/ddsl:$CI_SHA1
cmd: bundle exec rspec spec
- name: lint
type: docker
image: bilby91/ddsl:$CI_SHA1
cmd: rubocop .
Build
In order to run our feature-branch build we invoke
ddsl build feature-branch
Run
Now that we have our image built we can run things on it
ddsl run test lint
Environment Variables
- [ ] TODO
Documentation
For the moment, looking at how ddsl uses itself is the best documentation. You can find it here .ddsl.yml.
You can also look at how ddsl integrates with different CI providers
Schema
The .ddsl.yml schema documentation can found here
Continuous Integration
| Provider | Status |
|---|---|
| GitLab CI | |
| Circle CI | |
| Travis CI |
Contact
- Martín Fernández [email protected]
- Iván Etchart [email protected]