General tidying, cleanup and optimisation #2
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Lots of changes here:
It wasn't really feasible to change any of these, so the image is simple with them just assumed.
Port is hardcoded for simplicity and because docker allows port translation natively.
This helps general readability of the image and is possible with the above variables hardcoded.
UID
argument to change it's UID, allowing end users more fine grained control over directory permissionsThis makes the image size a little more representative and means less messing about with runtime volumes is needed, plus the image will now start quicker (particularly the first time it's run).
Host networking can be unpredictable as it exposes everything, whereas we know we only need the UDP 27015 port.
Bind mount is not really necessary here as people are very unlikely to ever desire to modify gmod game files; named volume is tidier and still allows modification either through the image or the host system.
If we want the collections mentioned in here, we could recommend them in the README?