diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile index 0ad4c4f..d650df2 100644 --- a/.devcontainer/Dockerfile +++ b/.devcontainer/Dockerfile @@ -1,27 +1,28 @@ -FROM mcr.microsoft.com/devcontainers/base:bookworm +FROM mcr.microsoft.com/devcontainers/go:1.25-bookworm -# Install common CLI tooling for Helm chart development and validation. -RUN apt-get update \ - && apt-get install -y --no-install-recommends \ - ca-certificates \ - curl \ - git \ - jq \ - python3 \ - python3-pip \ - shellcheck \ - yq \ - && rm -rf /var/lib/apt/lists/* +# Remove expired Yarn GPG key from base image +RUN sudo rm -f /etc/apt/sources.list.d/yarn.list -# Install the latest Helm 3 release. -RUN curl -fsSL https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 | bash +# Remove expired Yarn repository key (inherited from base image) +RUN sudo rm -f /etc/apt/sources.list.d/yarn.list -# Install the latest stable kubectl release. -RUN KUBECTL_VERSION="$(curl -fsSL https://dl.k8s.io/release/stable.txt)" \ - && curl -fsSL "https://dl.k8s.io/release/${KUBECTL_VERSION}/bin/linux/amd64/kubectl" -o /usr/local/bin/kubectl \ - && chmod +x /usr/local/bin/kubectl +# Install AZURE CLI +RUN curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash -# Install YAML linter via pip (available as yamllint command). -RUN pip3 install --no-cache-dir yamllint +# Install helm and kubectl +RUN curl https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3 | bash +RUN curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" \ + && chmod +x ./kubectl \ + && sudo mv ./kubectl /usr/local/bin/kubectl -USER vscode +# Install Argocd CLI +RUN VERSION=$(curl -L -s https://raw.githubusercontent.com/argoproj/argo-cd/stable/VERSION) +RUN curl -sSL -o argocd-linux-amd64 https://github.com/argoproj/argo-cd/releases/download/v$VERSION/argocd-linux-amd64 +RUN sudo install -m 555 argocd-linux-amd64 /usr/local/bin/argocd +RUN rm argocd-linux-amd64 + +# Install google-cloud-sdk +RUN echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] http://packages.cloud.google.com/apt cloud-sdk main" | sudo tee -a /etc/apt/sources.list.d/google-cloud-sdk.list +RUN curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo gpg --dearmor -o /usr/share/keyrings/cloud.google.gpg +RUN sudo apt-get update && sudo apt-get install -y google-cloud-cli +RUN sudo apt-get install google-cloud-cli-gke-gcloud-auth-plugin \ No newline at end of file diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 2a1e9bc..284099e 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -1,22 +1,23 @@ { - "name": "helm-charts-bookworm", - "runArgs": [ - "--name=kerberos-helm-charts", - "--network=host" - ], - "dockerFile": "Dockerfile", - "mounts": [ - "source=/var/run/docker.sock,target=/var/run/docker.sock,type=bind" - ], - "customizations": { - "vscode": { - "extensions": [ - "GitHub.copilot", - "ms-azuretools.vscode-docker", - "ms-kubernetes-tools.vscode-kubernetes-tools", - "redhat.vscode-yaml" - ] - } - }, - "postCreateCommand": "helm version && kubectl version --client && yamllint --version" + "name": "go:1.25-bookworm", + "dockerFile": "Dockerfile", + "runArgs": [ + "--name=helm-charts", + "--network=host", + "--privileged" + ], + "customizations": { + "vscode": { + "extensions": [ + "ms-kubernetes-tools.vscode-kubernetes-tools", + "redhat.vscode-yaml", + "Tim-Koehler.helm-intellisense", + "ms-vscode.azurecli", + "ms-vscode-remote.remote-containers", + "GitHub.copilot", + "ms-kubernetes-tools.vscode-aks-tools", + "fabiospampinato.vscode-diff" + ] + } + } }