mirror of
https://github.com/qdm12/ddns-updater.git
synced 2026-04-05 00:43:53 -04:00
Added development with remote containers
This commit is contained in:
19
.devcontainer/Dockerfile
Normal file
19
.devcontainer/Dockerfile
Normal file
@@ -0,0 +1,19 @@
|
||||
FROM golang:1.12.9-buster
|
||||
ENV DEBIAN_FRONTEND=noninteractive
|
||||
ARG USERNAME=vscode
|
||||
ARG USER_UID=1000
|
||||
ARG USER_GID=1000
|
||||
RUN apt-get update && \
|
||||
apt-get -y install --no-install-recommends apt-utils 2>&1 && \
|
||||
apt-get -y install git && \
|
||||
go get -u -v \
|
||||
github.com/ramya-rao-a/go-outline \
|
||||
golang.org/x/tools/cmd/gopls 2>&1 && \
|
||||
groupadd --gid $USER_GID $USERNAME && \
|
||||
useradd -s /bin/bash --uid $USER_UID --gid $USER_GID -m $USERNAME && \
|
||||
apt-get install -y sudo && \
|
||||
echo $USERNAME ALL=\(root\) NOPASSWD:ALL > /etc/sudoers.d/$USERNAME && \
|
||||
chmod 0440 /etc/sudoers.d/$USERNAME && \
|
||||
apt-get autoremove -y && \
|
||||
apt-get clean -y && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
Reference in New Issue
Block a user