Skip to content
Use docker-compose yml files as input for Hashicorp's nomad
Branch: master
Clone or download
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
examples Fix usage of entrypoint + command (and update example) Jan 13, 2017
helloworld Commit what I have + some README Dec 23, 2016
lib Split the command into args Jan 13, 2017
LICENSE Initial commit Dec 23, 2016
Makefile Commit what I have + some README Dec 23, 2016
README.md
compose2nomad.rb Support multiple input files from compose (to override some defaults) Jan 13, 2017
docker2nomad.rb Support multiple input files from compose (to override some defaults) Jan 13, 2017

README.md

nomad-compose

Use docker-compose yml files as input for Hashicorp's nomad

This script converts docker-compose yml files to nomad job templates

Usage: ./compose2nomad compose.yml [servicename]

This script resolves extends stanzas. You can add specific labels the compose file to influence some nomad-specific options, such as count, constraints, etc. The implementation depends on the setting. Examples:

    nomad.count: 1
    nomad.datacenters:
      - mydc
    nomad.constraints._cluster._type: constraint
    nomad.constraints._cluster.attribute: '${meta.role}'
    nomad.constraints._cluster.value: myrole
    nomad.constraints._distinct._type: constraint
    nomad.constraints._distinct.distinct_hosts: true

TODO:

  • currently only a single task is generated (while both compose and nomad support multiple tasks in a single file)
  • add more nomad-specific configuration options
You can’t perform that action at this time.