Skip to content

Commit 6aaaf48

Browse files
committed
template: dockerfile
1 parent 2b955bc commit 6aaaf48

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

.devcontainer/Dockerfile

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
ARG BASE_IMAGE=mcr.microsoft.com/devcontainers/base:ubuntu
2+
FROM ${BASE_IMAGE}
3+
4+
LABEL maintainer="franciuto"
5+
6+
# Keep non-interactive during any incidental package operations (we do not install here).
7+
ENV DEBIAN_FRONTEND=noninteractive
8+
ENV TZ=Etc/UTC
9+
ENV HOME=/home/vscode
10+
11+
# Ensure workspace and devcontainer folder exist, copy setup script but do not execute it.
12+
# Do not run apt installs or the setup script in this Dockerfile.
13+
COPY --chown=1000:1000 .devcontainer/setup.sh /workspaces/.devcontainer/setup.sh
14+
RUN chmod +x /workspaces/.devcontainer/setup.sh || true
15+
RUN mkdir -p /workspaces && chown -R 1000:1000 /workspaces
16+
17+
# Use the standard DevContainer non-root user
18+
USER vscode
19+
WORKDIR /workspaces
20+
21+
# Default command: open a shell. No setup actions performed here.
22+
CMD ["/bin/bash"]

0 commit comments

Comments
 (0)