Skip to content

Commit

Permalink
/storage file is now a volume towards ./.storage
Browse files Browse the repository at this point in the history
it's a volume, not a mount because I wasn't confortable using the user:root
and didn't want to go deeper in sysadmin stuff

can read more about difference between --mount and -v here: https://docs.docker.com/storage/volumes/#choose-the--v-or---mount-flag

rabbit hole here: moby/moby#2259
  • Loading branch information
M4rYu5 committed Nov 25, 2023
1 parent e0e0a9e commit b512951
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/movie_tracker/.gitignore
@@ -1,3 +1,7 @@
# sqlite files
MovieTracker/MovieTrackerMVC/MovieTrackerMVC.sqlite
MovieTracker/MovieTrackerMVC/MovieTrackerMVC.sqlite-shm
MovieTracker/MovieTrackerMVC/MovieTrackerMVC.sqlite-wal
MovieTracker/MovieTrackerMVC/MovieTrackerMVC.sqlite-wal

# local docker volume files
MovieTracker/.storage
8 changes: 8 additions & 0 deletions src/movie_tracker/MovieTracker/docker-compose.yml
Expand Up @@ -14,6 +14,14 @@ services:

storageapi:
image: ${DOCKER_REGISTRY-}storageapi
# user: root
# to use --mount (named) volume I would have to set user/group management for my containers
# I've found tools like https://github.com/boxboat/fixuid that can help
# but as of now, I don't plan to learn more about sysadmin stuff
# so I'm going to use a simple volume; read more here:
# https://docs.docker.com/storage/volumes/#choose-the--v-or---mount-flag
volumes:
- ./.storage:/storage
ports:
- "5043:8080"
build:
Expand Down

0 comments on commit b512951

Please sign in to comment.