Again, keep in mind, that while this starts and runs, when it comes time to mount a storage volume, it fails to do so as the curl command isn’t run, but is instead just spit our verbatim.
I used the Rancher-NFS catalog item with the following answers:
MOUNT_DIR=/
MOUNT_OPTS=nfsvers=4.1,rsize=1048576,wsize=1048576,hard,timeo=600,retrans=2
NFS_SERVER=$(curl -s http://169.254.169.254/latest/meta-data/placement/availability-zone).fs-1ac10853.efs.us-east-1.amazonaws.com
docker-compose
version: ‘2’
services:
nfs-driver:
privileged: true
image: rancher/storage-nfs:v0.6.0
environment:
MOUNT_DIR: /
MOUNT_OPTS: nfsvers=4.1,rsize=1048576,wsize=1048576,hard,timeo=600,retrans=2
NFS_SERVER: $$(curl -s http://169.254.169.254/latest/meta-data/placement/availability-zone).fs-1ac10853.efs.us-east-1.amazonaws.com
volumes:
- /run:/run
- /dev:/host/dev
- /var/lib/rancher/volumes:/var/lib/rancher/volumes:shared
logging:
driver: json-file
options:
max-file: ‘2’
max-size: 25m
pid: host
labels:
io.rancher.container.agent.role: environment
io.rancher.container.create_agent: ‘true’
io.rancher.scheduler.global: ‘true’
rancher-compose
version: ‘2’
services:
nfs-driver:
storage_driver:
description: null
name: rancher-nfs
volumeAccessMode: multiHostRW
I tried both the “blockquote” and the “Pre-formatted text” editing widgets in an attempt to preserve the indentation of the lines above, but neither worked. Odd that in a technical forum we have no obvious way to post “code”, or perhaps I’m just missing the option somewhere.