-
Notifications
You must be signed in to change notification settings - Fork 65
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create Dockerfile and docker's compose.yml file #27
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is pretty nice, and will be great for people who are familiar with Docker and want an easy way to run the server. I made a few comments/changes, could you take a look at them please?
ports: | ||
- mode: ingress | ||
target: 65535 | ||
published: "65535" | ||
protocol: tcp |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be shortened:
ports: | |
- mode: ingress | |
target: 65535 | |
published: "65535" | |
protocol: tcp | |
ports: | |
- 65535:65535/tcp |
networks: | ||
default: | ||
name: nanolimbo_default |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this section too since it's just the default network.
networks: | |
default: | |
name: nanolimbo_default |
networks: | ||
default: null |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This networks:
section should probably be removed since Compose creates one by default itself.
networks: | |
default: null |
context: . | ||
dockerfile: Dockerfile | ||
image: nanolimbo | ||
container_name: nanolimbo |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This container_name
option should be omitted so Docker Compose can pick its own name. Even if you won't be running multiple instances of this service on the same machine in different folders, there's no reason in favor of setting the container name.
See also: https://stackoverflow.com/a/64370490/19003757
container_name: nanolimbo |
I'm sorry I haven't noticed the comments until now, must've missed in my inbox. I can concede in most comments except the last one, the indentation seems correct in the bind mounts |
I guess I've seen it both ways in YAML, and it doesn't really affect the parsing. (I deleted that change just now, I wasn't sure how else to remove the suggestion) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should'nt the file for docker compose be named docker-compose.yml
instead of just compose.yml
?
docker-compose.yml is legacy naming, currently compose.yml is the go-to given that it is meant to be a more broad standard than just docker |
This PR provides a Dockerfile capable of compiling the source code with just doing
DOCKER_BUILDKIT=1 docker build
and running it inside of a container.Together with it is bundled a compose.yml file, which requires Docker CE to be installed (not the same as regular distro provided docker, haven't tested with it though).
This can easily be used to create an image for the end user to pull from the docker registry.
Fixes #13