Hi,
I try to use config into a compose file deployed with stack to deploy web.config.
version: '3.3'
services:
myservice:
image: me/myimage:latest
deploy:
replicas: 1
restart_policy:
condition: on-failure
delay: 10s
max_attempts: 3
window: 120s
configs:
- source: webconfig
target: c:\App\Web.config
volumes:
- document:c:\App\Document
ports:
- "80:80"
networks:
- frontend
configs:
webconfig:
file: config/web.config
volumes:
document:
networks:
frontend:
My image is based on microsoft/windowsservercore:1709, install and configure IIS and launch a Powershell script as entrypoint that affect user rights to application pool user to app directory.
This command works
icacls C:\App /GRANT 'IIS AppPool\DefaultAppPool:F' /t /q /L;
but IIS throw a 500.19 error “cannot read configuration file due to insuffisient permissions”
If I try to apply directly to the config file
icacls C:\ProgramData\Docker\internal\configs /GRANT 'IIS AppPool\DefaultAppPool:F' /t /q;`
it returns “Access is denied”
I have no more idea on what I am doing wrong. Do you have a clue ?