Concourse CI resource for watching changes of a single key in Hashicorp Consul.
A typical use case for fetching new values would be:
- create a resource instance that watches value of a given key in Consul
- when the value changes, generate a new resource version and run it through the pipeline
- retrieved key value is available to Concourse tasks
This resource also supports writing values to Consul.
Docker image: https://hub.docker.com/r/aptomi/concourse-consul-singlekey-resource
host
: Required Hostname or IP address of Consulport
: Optional, default443
Consul portscheme
: Optional, defaulthttps
Consul schemetoken
: Required Consul token to usekey
: Required Name of the key in Consul to watch
resource_types:
- name: consul-singlekey
type: docker-image
source:
repository: aptomi/concourse-consul-singlekey-resource
resources:
- name: consul
type: consul-singlekey
source:
host: consul.mycompany.com
token: f710a920-bb12-b356-ea1f-80f85f88f80b
key: aaa/bbb/ccc/ddd
No parameters.
One of those parameters should be specified:
value
- string value to be stored in a given Consul keyvalue_file
- read value from this file and store it in a given Consul key
To build the docker image for the resource:
python setup.py sdist
docker build -t <username>/concourse-consul-singlekey-resource .