chronos icon indicating copy to clipboard operation
chronos copied to clipboard

how to define a volume as readonly when define a docker job?

Open liqb opened this issue 6 years ago • 0 comments

In this example, the volume is set as "RW", how to set a volume as readonly? Do not include mode in the json?

{
  "schedule": "R/2014-09-25T17:22:00Z/PT2M",
  "name": "dockerjob",
  "container": {
    "type": "DOCKER",
    "image": "libmesos/ubuntu",
    "network": "BRIDGE",
    "volumes": [
      {
        "containerPath": "/var/log/",
        "hostPath": "/logs/",
        "mode": "RW"
      }
    ]
  },
  "cpus": "0.5",
  "mem": "512",
  "fetch": [],
  "command": "while sleep 10; do date =u %T; done"
}

liqb avatar Sep 25 '19 07:09 liqb