Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
GraphDeployer
Manage
Activity
Members
Labels
Plan
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Coscine
backend
scripts
GraphDeployer
Merge requests
!32
Fix: Fixed dev container
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Fix: Fixed dev container
Issue/xxxx-fixDevcontainer
into
master
Overview
0
Commits
1
Pipelines
1
Changes
2
Merged
L. Ellenbeck
requested to merge
Issue/xxxx-fixDevcontainer
into
master
8 months ago
Overview
0
Commits
1
Pipelines
1
Changes
2
Expand
0
0
Merge request reports
Compare
master
master (base)
and
latest version
latest version
d00de188
1 commit,
8 months ago
2 files
+
22
−
2
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
2
Search (e.g. *.vue) (Ctrl+P)
.devcontainer/Dockerfile
+
21
−
2
Options
# Development container for dotnet
FROM
mcr.microsoft.com/devcontainers/dotnet:8.0
as
develop
USER
vscode
ARG
USERNAME=vscode
ARG
USER_UID=1000
ARG
USER_GID=$USER_UID
# Remove any existing user with the same UID (if it's not the specified user)
RUN if
id
-u
$USER_UID
>
/dev/null 2>&1
;
then
\
existing_user
=
$(
getent passwd
$USER_UID
|
cut
-d
:
-f1
)
;
\
if
[
"
$existing_user
"
!=
"
$USERNAME
"
]
;
then
\
userdel
-f
$existing_user
;
\
fi
;
\
fi
# Change the user's GID and UID
RUN
groupmod
-g
$USER_GID
$USERNAME
\
&&
usermod
-u
$USER_UID
-g
$USER_GID
$USERNAME
# Change user folder owner and group
RUN
chown
-R
$USER_GID
:
$USER_GID
/home/
$USERNAME
# [Optional] Set the default user. Omit if you want to keep the default as root.
USER
$USERNAME
# Add nuget sources for private packages (here: api-client)
RUN
dotnet nuget add
source
"https://git.rwth-aachen.de/api/v4/projects/88930/packages/nuget/index.json"
-n
"api-client"
\ No newline at end of file
Loading