Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix: run code-server as the appropriate user#1

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
DanielleMaywood merged 3 commits intomainfromdm-run-user-at-right-perm-level
Apr 8, 2025

Conversation

DanielleMaywood
Copy link
Collaborator

Rather than run code-server as root, we instead run it as the appropriate user.

Rather than run code-server as root, we instead run it as theappropriate user.
@DanielleMaywoodDanielleMaywood self-assigned thisApr 8, 2025
@DanielleMaywoodDanielleMaywood marked this pull request as ready for reviewApril 8, 2025 10:38
@@ -22,7 +22,7 @@ cat > /usr/local/bin/code-server-entrypoint \
#!/usr/bin/env bash
set -e

code-server --bind-addr "$HOST:$PORT" \$ARGS
runuser -l $_REMOTE_USER -c 'code-server --bind-addr "$HOST:$PORT" \$ARGS'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Is there anything that guaranteesrunuser is present? I know it's present in both Debian and Ubuntu, but for instance containers like Alpine and Fedora don't have it.

Copy link
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

That's a good point, I've switched tosu instead.

Copy link
Member

@mafredrimafredri left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

:shipit:

@@ -22,7 +22,7 @@ cat > /usr/local/bin/code-server-entrypoint \
#!/usr/bin/env bash
set -e

code-server --bind-addr "$HOST:$PORT" \$ARGS
su $_REMOTE_USER -c 'code-server --bind-addr "$HOST:$PORT" \$ARGS'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Sanity check: Is this remote user env always set?

Copy link
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

@DanielleMaywoodDanielleMaywood merged commita49fbbb intomainApr 8, 2025
7 checks passed
@DanielleMaywoodDanielleMaywood deleted the dm-run-user-at-right-perm-level branchApril 10, 2025 09:55
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@mafredrimafredrimafredri approved these changes

Assignees

@DanielleMaywoodDanielleMaywood

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@DanielleMaywood@mafredri

[8]ページ先頭

©2009-2025 Movatter.jp