Skip to content
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

/entrypoint.sh: 34: exec: 1000:1000: not found #178

Closed
drees-clark opened this issue Apr 22, 2024 · 8 comments
Closed

/entrypoint.sh: 34: exec: 1000:1000: not found #178

drees-clark opened this issue Apr 22, 2024 · 8 comments

Comments

@drees-clark
Copy link

drees-clark commented Apr 22, 2024

Had Flatnotes running perfectly in Docker on Synology NAS.
Possibly after this latest update the container stops with above error.

EDIT:
Image used: dullage/Flatnotes:latest
I tried different users in PUID and PGID, from root to admin to normal user account.

@Code-Otto
Copy link
Contributor

Oh whoops, this is related to my merged changes here:
43b2ee0#diff-6f9d41d046756f0ddc2fcee0626bdb50100d12b88f293734eff742818e03efa2L34-R34

This PR added a new experimental Alpine Linux-based Dockerfile which results in a much smaller Flatnotes container image.
Since the gosu tool used at the entrypoint is not available at Alpine Linux we used the equivalent su-exec instead. To keep the same entrypoint script compatible with both images I added a EXEC_TOOL variable to the Dockerfile telling the command of the tool (either EXEC_TOOL=gosu or EXEC_TOOL=su-exec)

However looks like when updating the Docker container this environment variable doesn't gets defined and is causing the script to fail

A fix for this would be adding the following to the /entrypoint.sh script to keep it working for existing users:

if [ ! "$EXEC_TOOL" ]; then
    EXEC_TOOL=gosu
fi

As a hotfix while the fix is ready you can try manually adding the above to the beginning of this script inside the container, or just reinstalling Flatnotes

@drees-clark
Copy link
Author

drees-clark commented Apr 22, 2024

Thank you for the clarification and explanation. Unfortunately, I'm unable to find the entrypoint.sh file.
Can you give me pointers as to where the file might be in a Docker environment on Synology NAS?

EDIT:
Nevermind, I replicated the stack, and miraculously it works again now.

@drees-clark
Copy link
Author

See comment by Code-Otto

@banjuer
Copy link

banjuer commented Apr 23, 2024

Oh whoops, this is related to my merged changes here: 43b2ee0#diff-6f9d41d046756f0ddc2fcee0626bdb50100d12b88f293734eff742818e03efa2L34-R34

This PR added a new experimental Alpine Linux-based Dockerfile which results in a much smaller Flatnotes container image. Since the gosu tool used at the entrypoint is not available at Alpine Linux we used the equivalent su-exec instead. To keep the same entrypoint script compatible with both images I added a EXEC_TOOL variable to the Dockerfile telling the command of the tool (either EXEC_TOOL=gosu or EXEC_TOOL=su-exec)

However looks like when updating the Docker container this environment variable doesn't gets defined and is causing the script to fail

A fix for this would be adding the following to the /entrypoint.sh script to keep it working for existing users:

if [ ! "$EXEC_TOOL" ]; then
    EXEC_TOOL=gosu
fi

As a hotfix while the fix is ready you can try manually adding the above to the beginning of this script inside the container, or just reinstalling Flatnotes

wil it merged into next release? unfortunately, i met the same issue and i don't no how to edit this code in docker...

@Code-Otto
Copy link
Contributor

I've opened a pull request with a proposed fix
Since I'm not a maintainer I cannot do the changes directly however expect that when @dullage is back an updated image with the fix will be available soon

@dullage
Copy link
Owner

dullage commented Apr 24, 2024

Fix is now available in v4.0.4. Thanks @Code-Otto.

@dullage
Copy link
Owner

dullage commented Apr 24, 2024

@banjuer - Were you also running flatnotes on a Synology?

@banjuer
Copy link

banjuer commented Apr 24, 2024

@banjuer - Were you also running flatnotes on a Synology?

yes and now it worked well in v4.0.4, Thank you all !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants