Skip to content

Docker image: Move binary to /usr/local/bin for PATH access#43

Merged
jmetrikat merged 2 commits intoanyproto:mainfrom
florian-h05:patch-1
Apr 19, 2026
Merged

Docker image: Move binary to /usr/local/bin for PATH access#43
jmetrikat merged 2 commits intoanyproto:mainfrom
florian-h05:patch-1

Conversation

@florian-h05
Copy link
Copy Markdown
Contributor

This allows calling anytype CLI without needing to use the full path.


  • I understand that contributing to this repository will require me to agree with the CLA

Description

This PR adds the feature to invoke the anytype command in the container image without needing to use the full path.

What type of PR is this? (check all applicable)

  • 🍕 Feature
  • 🐛 Bug Fix
  • 📝 Documentation Update
  • 🎨 Style
  • 🧑‍💻 Code Refactor
  • 🔥 Performance Improvements
  • ✅ Test
  • 🤖 Build
  • 🔁 CI

Related Tickets & Documents

Mobile & Desktop Screenshots/Recordings

Added tests?

  • 👍 yes
  • 🙅 no, because they aren't needed
  • 🙋 no, because I need help

Added to documentation?

  • 📜 README.md
  • 📓 tech-docs
  • 🙅 no documentation needed

[optional] Are there any post-deployment tasks we need to perform?

This allows calling anytype CLI without needing to use the full path.
@jmetrikat jmetrikat self-requested a review April 19, 2026 09:13
@jmetrikat
Copy link
Copy Markdown
Collaborator

Thanks @florian-h05! An alternative worth considering: instead of extending PATH, we could also copy the binary to /usr/local/bin/anytype (already on PATH in the base image).

Should be the same outcome for your use case, no ENV needed, and even more idiomatic as it follows the standard fs layout. wdyt?

COPY anytype-linux-${TARGETARCH} /usr/local/bin/anytype                                                                                       
RUN chmod +x /usr/local/bin/anytype                       
...                                                                                                                                           
ENTRYPOINT ["anytype"]

@florian-h05
Copy link
Copy Markdown
Contributor Author

That also works!
I decided to go with the $PATH variable as this was the most minimal change, but as nothing depends on the actual path, we can change it 👍

@jmetrikat
Copy link
Copy Markdown
Collaborator

@florian-h05 great push! makes sense, i'll get your PR in and release a new version in a moment :)

@jmetrikat jmetrikat changed the title Docker image: Add /app to $PATH Docker image: Move binary to /usr/local/bin for PATH access Apr 19, 2026
@jmetrikat jmetrikat merged commit e3dc79b into anyproto:main Apr 19, 2026
5 checks passed
@jmetrikat
Copy link
Copy Markdown
Collaborator

@florian-h05 https://github.com/anyproto/anytype-cli/releases/tag/v0.1.15

@florian-h05 florian-h05 deleted the patch-1 branch April 19, 2026 18:09
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

Successfully merging this pull request may close these issues.

2 participants