clair-scanner icon indicating copy to clipboard operation
clair-scanner copied to clipboard

Docker-compose

Open CaosFR opened this issue 5 years ago • 0 comments

Hi,

I try to improve the start and stop of clair-scanner with a single docker-compose file.

docker-compose.yml

version: '1'
services:
  arminc_clair-db:
    container_name: db
    image: arminc/clair-db:latest
    restart: unless-stopped
    ports:
      - "5430:5430"

  arminc_clair-local-scan:
    container_name: clair
    image: arminc/clair-local-scan:latest
    restart: unless-stopped
    depends_on:
      - arminc/clair-db
    ports:
      - "6060:6060"
    links:
      - arminc/clair-db

I use two specials options, "depends_on" for start "arminc/clair-db" in first and "links" for the postgres db. Does this file look good or may be improve ?

This docker-compose file work for me. Maybe it's a good idea to add this kind of file to the master ?

TY

CaosFR avatar Jun 12 '19 11:06 CaosFR