Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tambeta/ddeploy
Simple Docker deployment tool
https://github.com/tambeta/ddeploy
Last synced: about 14 hours ago
JSON representation
Simple Docker deployment tool
- Host: GitHub
- URL: https://github.com/tambeta/ddeploy
- Owner: tambeta
- License: mit
- Created: 2018-12-13T13:11:49.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2019-03-18T16:36:40.000Z (over 5 years ago)
- Last Synced: 2023-07-21T18:15:15.582Z (over 1 year ago)
- Language: Shell
- Size: 9.77 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ddeploy
A tool for deploying an application from a Git repository to a remote host using
[Docker Compose](https://docs.docker.com/compose/), according to a configuration
provided in a `docker-compose.yml` file. Run `ddeploy` in a directory
containing the configuration file to make the magic happen.
[yq](https://github.com/kislyuk/yq/) is the only dependency besides standard
GNU tools.## Configuration
`ddeploy` configuration mostly happens via `docker-compose.yml` containing a
special [extension
field](https://docs.docker.com/compose/compose-file/#extension-fields)
`x-ddeploy-conf` (in addition to standard sections such as `services`).
Configuration subkeys:* `deploy_host` - *String* Deploy target host name.
* `deploy_workdir` - *String* A directory for deployment infrastructure files,
will be created if nonexistent. This may be a transient directory.
* `services` - *Mapping* Service IDs linked to a mapping, containing the
following keys:
* `deploy_dir` - *String* Service directory on the deploy host. This is
expected to be present and be a Git working directory. On deploy, the
configured ref will be fetched and checked out. Generally this directory is
also expected to be mounted onto the container, but this is up to standard
Docker Compose configuration.
* `ref` - *String* The Git ref to be fetched and checked out on deploy. Making
this configurable on the command line is TODO.The values in `services` will also be made available for later use via the
[env file](https://docs.docker.com/compose/env-file/). Variable names are
constructed by prefixing the configuration key with the service ID. E.g. the
key```
services:
webapp:
deploy_dir: "/opt/docker/webapp"
```will become available as `${webapp_deploy_dir}`.
See `docker-compose.example.yml` for an example.
## Command-line options:
* `-f` - Foreground mode: do not pass `--detach` to `docker compose up`.