feat(devcontainer): simplify image (#3205)

This simplifies the devcontainer using the builder image as the base and adding the common-utils feature (which takes care of creating the vscode user and more).
This commit is contained in:
Alberto García
2025-02-06 08:28:41 +00:00
committed by GitHub
parent 8188190113
commit c82d2de6b0
2 changed files with 8 additions and 16 deletions
-9
View File
@@ -1,9 +0,0 @@
ARG VARIANT="rawhide"
FROM fedora:${VARIANT}
RUN useradd -m vscode
RUN groupadd mock
RUN usermod -aG mock vscode
RUN echo vscode ALL=\(root\) NOPASSWD:ALL > /etc/sudoers.d/vscode
RUN curl -Lo /etc/yum.repos.d/terra.repo https://raw.githubusercontent.com/terrapkg/subatomic-repos/main/terra.repo
RUN dnf -y install git mock createrepo_c anda terra-mock-configs
+8 -7
View File
@@ -1,18 +1,19 @@
{
"name": "Fedora",
"build": {
"dockerfile": "Dockerfile",
"args": { "VARIANT": "rawhide" }
},
"remoteUser": "vscode",
"name": "Terra Devcontainer",
"image": "ghcr.io/terrapkg/builder:frawhide",
"runArgs": [
"--privileged"
],
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {}
},
"customizations": {
"vscode": {
"extensions": [
"rhaiscript.vscode-rhai"
]
}
}
},
"remoteUser": "vscode",
"onCreateCommand": "sudo usermod -a -G mock vscode"
}