[1.x] Remove the default ubuntu
user
#762
Merged
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.
Fixes #761
In #758 the base image was changed from
20.04
and22.04
to24.04
which caused some permission errors.It seems that as of Ubuntu 23.04 the base image comes with a default user named
ubuntu
. This causes the app files to be owned by that user instead of the expectedsail
user. This PR removes the defaultubuntu
user before thesail
user is created.More info here: https://askubuntu.com/questions/1513927/ubuntu-24-04-docker-images-now-includes-user-ubuntu-with-uid-gid-1000
Before:
![image](https://private-user-images.githubusercontent.com/1123887/390466571-b28ad3da-6f63-406f-a375-e426951f17c6.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkzNjE2MTcsIm5iZiI6MTczOTM2MTMxNywicGF0aCI6Ii8xMTIzODg3LzM5MDQ2NjU3MS1iMjhhZDNkYS02ZjYzLTQwNmYtYTM3NS1lNDI2OTUxZjE3YzYucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI1MDIxMiUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNTAyMTJUMTE1NTE3WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFt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