neilhwatson / evolve_cfengine_freelib

Evolve Thinking's free Cfengine promise library.
18 stars 5 forks source link

Add docker management bundle #26

Open neilhwatson opened 7 years ago

neilhwatson commented 7 years ago

Requirements:

  1. Promise Dockerfile and supporting files from cf-serverd.
  2. If above promise is repaired then 'force' both image build and container restart. Use --restart=unless-stopped for run and --rm=true for images.
  3. If promise 1 is kept then ensure defined image is present and container is running.

How to do the last promise the least invasive way given CFEngine has not docker aware parts? Commands must be used.

Data required:

  1. File src on cf-serverd.
  2. File destination on agent host.
  3. Image and container name.
  4. Image tag (maybe)
  5. Docker capabilities.
  6. Volumes (nice to have)

Possible checks:

  1. docker images -q pcf_dns:latest
  2. docker ps -q --filter=name=pcf_dns
tzz commented 7 years ago

Separate building, from image management, from running (lifecycle management).

Look at integrating with 1.12 Swarm.

neilhwatson commented 7 years ago

See #27 For building images.