2020-03-16 12:53:04 +00:00
|
|
|
# jobspec for running CSI plugin for AWS EFS, derived from
|
|
|
|
# the kubernetes manifests found at
|
|
|
|
# https://github.com/kubernetes-sigs/aws-efs-csi-driver/tree/master/deploy/kubernetes
|
|
|
|
|
|
|
|
job "plugin-aws-efs-nodes" {
|
|
|
|
datacenters = ["dc1"]
|
|
|
|
|
2020-04-06 15:57:59 +00:00
|
|
|
constraint {
|
|
|
|
attribute = "${attr.kernel.name}"
|
|
|
|
value = "linux"
|
|
|
|
}
|
|
|
|
|
2020-03-16 12:53:04 +00:00
|
|
|
# you can run node plugins as service jobs as well, but this ensures
|
|
|
|
# that all nodes in the DC have a copy.
|
|
|
|
type = "system"
|
|
|
|
|
|
|
|
group "nodes" {
|
|
|
|
task "plugin" {
|
|
|
|
driver = "docker"
|
|
|
|
|
|
|
|
config {
|
2022-03-21 15:48:47 +00:00
|
|
|
image = "amazon/aws-efs-csi-driver:v1.3.6"
|
2020-03-16 12:53:04 +00:00
|
|
|
args = [
|
|
|
|
"node",
|
2022-03-21 15:48:47 +00:00
|
|
|
"--endpoint=${CSI_ENDPOINT}",
|
2020-03-16 12:53:04 +00:00
|
|
|
"--logtostderr",
|
|
|
|
"--v=5",
|
|
|
|
]
|
|
|
|
|
|
|
|
privileged = true
|
|
|
|
}
|
|
|
|
|
2022-03-21 15:48:47 +00:00
|
|
|
# note: the EFS driver doesn't seem to respect the --endpoint
|
|
|
|
# flag or CSI_ENDPOINT env var and always sets up the listener
|
|
|
|
# at '/tmp/csi.sock'
|
2020-03-16 12:53:04 +00:00
|
|
|
csi_plugin {
|
|
|
|
id = "aws-efs0"
|
|
|
|
type = "node"
|
|
|
|
mount_dir = "/tmp"
|
|
|
|
}
|
|
|
|
|
|
|
|
# note: there's no upstream guidance on resource usage so
|
|
|
|
# this is a best guess until we profile it in heavy use
|
|
|
|
resources {
|
|
|
|
cpu = 500
|
|
|
|
memory = 256
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|