don't create cache/log volume
This commit is contained in:
parent
5907008f2b
commit
f7f5c5aa8d
|
@ -3,9 +3,10 @@
|
|||
dockerTools.buildLayeredImage {
|
||||
name = "nginx";
|
||||
contents = [ nginx ];
|
||||
# also we log to stderr, it still needs /var/log/nginx on start
|
||||
extraCommands = ''
|
||||
mkdir -p etc
|
||||
chmod u+w etc
|
||||
mkdir -p etc var/cache/nginx var/log/nginx
|
||||
chmod u+w etc var/cache/nginx var/log/nginx
|
||||
echo "nginx:x:1000:1000::/:" > etc/passwd
|
||||
echo "nginx:x:1000:nginx" > etc/group
|
||||
'';
|
||||
|
|
|
@ -22,13 +22,9 @@ in {
|
|||
imagePullPolicy = "IfNotPresent";
|
||||
volumeMounts."/etc/nginx".name = "config";
|
||||
volumeMounts."/var/lib/html".name = "static";
|
||||
volumeMounts."/var/log/nginx".name = "logs";
|
||||
volumeMounts."/var/log/cache".name = "cache";
|
||||
};
|
||||
volumes.config.configMap.name = "nginx-config";
|
||||
volumes.static.configMap.name = "nginx-static";
|
||||
volumes.logs.configMap.name = "nginx-logs";
|
||||
volumes.cache.configMap.name = "nginx-cache";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue