I am trying to change ownership of static directory in a container but for some reason it's not working but it works on another directory.
securityContext:
runAsUser: 0
command: ["/bin/sh"]
args:
- -c
- |
chown -R www-data:www-data /var/www/html/pub/media
chown -R www-data:www-data /var/www/html/pub/static
When I run kubectl -n magento exec magento-web-dweq34672 -- ls -al var/www/html/pub I see static directory still under root ownership. everytime I Am manually changing it using following which is getting frustrating now, any suggestions
kubectl -n magento exec magento-web-dweq34672 -- chown -R www-data:www-data var/www/html/pub