From 75483a4c5f99f3ba4514a3298f9cff64a3b2b8df Mon Sep 17 00:00:00 2001 From: Vitalii Mikhailov Date: Sat, 27 Apr 2024 23:08:29 +0300 Subject: [PATCH] Using shared infrastructure --- .devcontainer/7z/devcontainer-feature.json | 7 ---- .devcontainer/7z/install.sh | 10 ------ .devcontainer/Dockerfile | 23 ------------- .devcontainer/devcontainer.json | 32 +++++++------------ .../upgrade/devcontainer-feature.json | 7 ---- .devcontainer/upgrade/install.sh | 10 ------ .../vortex/devcontainer-feature.json | 14 -------- .devcontainer/vortex/install.sh | 2 -- 8 files changed, 12 insertions(+), 93 deletions(-) delete mode 100644 .devcontainer/7z/devcontainer-feature.json delete mode 100644 .devcontainer/7z/install.sh delete mode 100644 .devcontainer/Dockerfile delete mode 100644 .devcontainer/upgrade/devcontainer-feature.json delete mode 100644 .devcontainer/upgrade/install.sh delete mode 100644 .devcontainer/vortex/devcontainer-feature.json delete mode 100644 .devcontainer/vortex/install.sh diff --git a/.devcontainer/7z/devcontainer-feature.json b/.devcontainer/7z/devcontainer-feature.json deleted file mode 100644 index f2b8ad8..0000000 --- a/.devcontainer/7z/devcontainer-feature.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "id": "7z", - "version": "1.0.0", - "name": "7z", - "documentationURL": "", - "description": "7z" -} \ No newline at end of file diff --git a/.devcontainer/7z/install.sh b/.devcontainer/7z/install.sh deleted file mode 100644 index 26a7c61..0000000 --- a/.devcontainer/7z/install.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/bash -export DEBIAN_FRONTEND=noninteractive - -echo "(*) Installing 7z" -apt-get update -apt-get install -y --no-install-recommends p7zip-full -apt-get clean -y -rm -rf /var/lib/apt/lists/*; - -echo "Done!" \ No newline at end of file diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile deleted file mode 100644 index 85cc3cd..0000000 --- a/.devcontainer/Dockerfile +++ /dev/null @@ -1,23 +0,0 @@ -# [Choice] Debian version (use bullseye on local arm64/Apple Silicon): bookworm, bullseye, buster -ARG VARIANT="bookworm" -FROM buildpack-deps:${VARIANT}-curl - -USER root - -ARG USERNAME=developer -ARG USER_UID=1000 -ARG USER_GID=$USER_UID - -# Create the user -RUN groupadd --gid $USER_GID $USERNAME \ - && useradd -s /bin/bash --uid $USER_UID --gid $USER_GID -m $USERNAME \ - # - # [Optional] Add sudo support. Omit if you don't need to install software after connecting. - && apt-get update \ - && apt-get install -y sudo \ - && echo $USERNAME ALL=\(root\) NOPASSWD:ALL > /etc/sudoers.d/$USERNAME \ - && chmod 0440 /etc/sudoers.d/$USERNAME - -USER $USERNAME - -LABEL org.opencontainers.image.source="https://github.com/butr/game-mount-and-blade2" \ No newline at end of file diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index d894a58..c2ed40f 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -1,21 +1,15 @@ { "name": "NodeJS & Powershell & 7z", - "dockerFile": "Dockerfile", - "build": { - "cacheFrom": "ghcr.io/butr/game-mount-and-blade2-devcontainer:latest" - }, + "image": "ghcr.io/butr/devcontainer:latest", "features": { - //"ghcr.io/stuartleeks/dev-container-features/shell-history:0": { - // - //}, - "./upgrade": { + "ghcr.io/butr/devcontainer/upgrade:1": { }, "ghcr.io/devcontainers/features/git:1": { "version": "latest", "ppa": "false" }, - "./7z": { + "ghcr.io/butr/devcontainer/7z:1": { }, "ghcr.io/devcontainers/features/node:1": { @@ -24,23 +18,21 @@ }, "ghcr.io/devcontainers/features/powershell:1": { "version": "latest" - }, - "./vortex": { - } }, "overrideFeatureInstallOrder": [ - //"ghcr.io/stuartleeks/dev-container-features/shell-history", - "./upgrade", + "ghcr.io/butr/devcontainer/upgrade", "ghcr.io/devcontainers/features/git", - "./7z", + "ghcr.io/butr/devcontainer/7z", "ghcr.io/devcontainers/features/node", - "ghcr.io/devcontainers/features/powershell", - "./vortex" + "ghcr.io/devcontainers/features/powershell" ], - "mounts": [ - //"source=profile,target=/home/developer,type=volume", - //"target=/home/developer/.vscode-server,type=volume", + "mounts": [ + { + "source":"${localEnv:HOME}${localEnv:USERPROFILE}/AppData/Roaming/Vortex/plugins", + "target":"/vortex-plugins", + "type":"bind" + } ], "postAttachCommand": "yarn install", "customizations": { diff --git a/.devcontainer/upgrade/devcontainer-feature.json b/.devcontainer/upgrade/devcontainer-feature.json deleted file mode 100644 index 722ab1f..0000000 --- a/.devcontainer/upgrade/devcontainer-feature.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "id": "upgrade", - "version": "1.0.0", - "name": "Upgrade", - "documentationURL": "", - "description": "Upgrade" -} \ No newline at end of file diff --git a/.devcontainer/upgrade/install.sh b/.devcontainer/upgrade/install.sh deleted file mode 100644 index fabb56b..0000000 --- a/.devcontainer/upgrade/install.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/bash -export DEBIAN_FRONTEND=noninteractive - -echo "(*) Upgrading" -apt-get update -apt-get upgrade -y -apt-get clean -y -rm -rf /var/lib/apt/lists/*; - -echo "Done!" \ No newline at end of file diff --git a/.devcontainer/vortex/devcontainer-feature.json b/.devcontainer/vortex/devcontainer-feature.json deleted file mode 100644 index 9f52d2d..0000000 --- a/.devcontainer/vortex/devcontainer-feature.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "id": "vortex", - "version": "1.0.0", - "name": "Vortex", - "documentationURL": "", - "description": "Vortex", - "mounts": [ - { - "source":"${localEnv:HOME}${localEnv:USERPROFILE}/AppData/Roaming/Vortex/plugins", - "target":"/vortex-plugins", - "type":"bind" - } - ] - } \ No newline at end of file diff --git a/.devcontainer/vortex/install.sh b/.devcontainer/vortex/install.sh deleted file mode 100644 index a4fb79f..0000000 --- a/.devcontainer/vortex/install.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -export DEBIAN_FRONTEND=noninteractive \ No newline at end of file