🐛 FIX: build / run issues with docker mount points

- using ./ instead of ${PWD} is more universal and doesn't depend on the corresponding env variable to be set in the environment
- when mounting /app/lastIp, docker wants this to be a directory and not a file for it to work

Signed-off-by: Jonas Sulzer <jonas@violoncello.ch>
This commit is contained in:
Jonas Sulzer 2020-12-18 23:43:36 +01:00
parent 67d8eda971
commit a9731b30a4
Signed by untrusted user: jonas
GPG Key ID: 6D1DC8E0D9904C83
2 changed files with 4 additions and 4 deletions

View File

@ -4,9 +4,9 @@ services:
build: '.' build: '.'
container_name: dyndns container_name: dyndns
volumes: volumes:
- ${PWD}/src:/app/src - ./src:/app/src
- ${PWD}/log:/app/log - ./log:/app/log
- ${PWD}/lastIp:/app/lastIp - ./lastIp:/app/lastIp
env_file: env_file:
- app.env - app.env

View File

@ -18,7 +18,7 @@ logging.config.fileConfig(fname=loggerConfigPath, defaults={'logfilename': f'{ho
logger = logging.getLogger(__name__) logger = logging.getLogger(__name__)
ipFile = f'{home}/lastIp' ipFile = f'{home}/lastIp/ip'
timeout = 60 timeout = 60
if __name__ == "__main__": if __name__ == "__main__":