Skip to content

Instantly share code, notes, and snippets.

@gurvindersingh
Created September 30, 2016 05:24
Show Gist options
  • Save gurvindersingh/e621eea2d9c60bafe1b121b88e8002b7 to your computer and use it in GitHub Desktop.
Save gurvindersingh/e621eea2d9c60bafe1b121b88e8002b7 to your computer and use it in GitHub Desktop.
[Unit]
Description=Mount Gluster using rkt fly shared mount on host
[Service]
ExecStartPre=/bin/bash -c 'umount -l /gluster || true'
ExecStart=/usr/bin/rkt run \
--insecure-options=image docker://gurvin/gluster-client:0.1.3 \
--stage1-name=coreos.com/rkt/stage1-fly:1.12.0 \
--volume mnt,kind=host,source=/daas,readOnly=false \
--mount volume=mnt,target=/mnt \
--set-env='SERVERS=gluster1.com,gluster2.com' \
--set-env='VOLUME=/gluster' \
--set-env='MOUNTHPATH=/mnt' \
--volume resolv,kind=host,source=/etc/resolv.conf,readOnly=true \
--mount volume=resolv,target=/etc/resolv.conf
Restart=always
RestartSec=10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment