From 6c128b7988e19e6b8103c9b565f26ce02abcb14e Mon Sep 17 00:00:00 2001 From: Kat Morgan Date: Mon, 22 Jan 2024 22:24:47 +0000 Subject: [PATCH] layout redesign for modular support --- .devcontainer/Dockerfile | 3 + .devcontainer/README.md | 4 + .devcontainer/devcontainer.json | 80 ++++++++ .devcontainer/devcontainer/Dockerfile | 3 + .devcontainer/devcontainer/devcontainer.json | 80 ++++++++ .devcontainer/devcontainer/extra/Dockerfile | 185 ++++++++++++++++++ .../devcontainer/extra/devcontainer.json | 80 ++++++++ .../devcontainer/kind/devcontainer.json | 80 ++++++++ .devcontainer/extra/Dockerfile | 185 ++++++++++++++++++ .devcontainer/extra/devcontainer.json | 80 ++++++++ .devcontainer/kind/devcontainer.json | 80 ++++++++ .frontmatter/database/taxonomyDb.json | 1 - .github/devcontainer | 1 + .gitmodules | 3 + .gitpod.yml | 1 - Makefile | 2 +- 16 files changed, 865 insertions(+), 3 deletions(-) create mode 100644 .devcontainer/Dockerfile create mode 100644 .devcontainer/README.md create mode 100644 .devcontainer/devcontainer.json create mode 100644 .devcontainer/devcontainer/Dockerfile create mode 100644 .devcontainer/devcontainer/devcontainer.json create mode 100644 .devcontainer/devcontainer/extra/Dockerfile create mode 100644 .devcontainer/devcontainer/extra/devcontainer.json create mode 100644 .devcontainer/devcontainer/kind/devcontainer.json create mode 100644 .devcontainer/extra/Dockerfile create mode 100644 .devcontainer/extra/devcontainer.json create mode 100644 .devcontainer/kind/devcontainer.json delete mode 100644 .frontmatter/database/taxonomyDb.json create mode 160000 .github/devcontainer create mode 100644 .gitmodules delete mode 100644 .gitpod.yml diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile new file mode 100644 index 0000000..0e5ee85 --- /dev/null +++ b/.devcontainer/Dockerfile @@ -0,0 +1,3 @@ +FROM ghcr.io/pulumi/devcontainer:latest + +# Add any additional packages and customization for your project here. \ No newline at end of file diff --git a/.devcontainer/README.md b/.devcontainer/README.md new file mode 100644 index 0000000..3fe817b --- /dev/null +++ b/.devcontainer/README.md @@ -0,0 +1,4 @@ +# DO NOT EDIT DIRECTLY + +See submodule maintainer docs for instructions on how to change devcontainer configuration(s). +Changes will be overwritten. \ No newline at end of file diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json new file mode 100644 index 0000000..4965b35 --- /dev/null +++ b/.devcontainer/devcontainer.json @@ -0,0 +1,80 @@ +// Reference: +// - https://containers.dev/features +// - https://containers.dev/implementors/features +// - https://containers.dev/implementors/json_reference +// - https://code.visualstudio.com/docs/getstarted/settings +{ + "name": "pulumi", + "dockerFile": "Dockerfile", + "customizations": { + "vscode": { + "settings": { + // https://github.com/VSCodeVim/Vim + "vim.disableExtension": true, + "vim.easymotion": true, + "vim.incsearch": true, + "vim.useSystemClipboard": true, + "vim.useCtrlKeys": true, + "vim.hlsearch": true, + "vim.insertModeKeyBindings": [ + { + "before": ["j", "j"], + "after": [""] + } + ], + "vim.handleKeys": { + "": false, + "": false + }, + "extensions.experimental.affinity": { + "vscodevim.vim": 1 + }, + "go.testTags": "all", + "go.buildTags": "all", + "editor.minimap.enabled": false, + "editor.lineNumbers": "relative", + "editor.quickSuggestionsDelay": 0, + "editor.suggestSelection": "first", + "editor.snippetSuggestions": "top", + "editor.gotoLocation.multipleReferences": "goto", + "editor.gotoLocation.multipleDefinitions": "goto", + "editor.gotoLocation.multipleDeclarations": "goto", + "editor.gotoLocation.multipleImplementations": "goto", + "editor.gotoLocation.multipleTypeDefinitions": "goto", + "editor.terminal.integrated.shell.linux": "/usr/bin/bash", + "terminal.integrated.shell.linux": "/usr/bin/bash", + "terminal.integrated.sendKeybindingsToShell": true, + "workbench.colorTheme": "Dracula Soft", + "explorer.openEditors.visible": 1, + "files.trimTrailingWhitespace": true, + "files.trimFinalNewlines": true + }, + "extensions": [ + "golang.go", + "vscodevim.vim", + "github.copilot", + "vscodevim.vim", + "ms-python.python", + "redhat.vscode-yaml", + "esbenp.prettier-vscode", + "ms-vsliveshare.vsliveshare", + "ms-azuretools.vscode-docker", + "github.vscode-github-actions", + "ms-vscode.vscode-typescript-next", + "github.vscode-pull-request-github", + "ms-vscode-remote.remote-containers", + "visualstudioexptteam.vscodeintellicode", + "bierner.markdown-preview-github-styles" + ] + } + }, + "features": { + "ghcr.io/devcontainers/features/docker-outside-of-docker:1": {} + }, + "mounts": ["source=dind-var-lib-docker,target=/var/lib/docker,type=volume"], + "remoteUser": "vscode", + "overrideCommand": false, + "runArgs": ["--init", "--privileged", "--network=host"], + "postCreateCommand": "sudo chown $USER /workspaces/* 2>/dev/null || true; direnv allow 2>/dev/null || true", + "forwardPorts": [1313, 2222, 6000, 7681, 8080] +} diff --git a/.devcontainer/devcontainer/Dockerfile b/.devcontainer/devcontainer/Dockerfile new file mode 100644 index 0000000..0e5ee85 --- /dev/null +++ b/.devcontainer/devcontainer/Dockerfile @@ -0,0 +1,3 @@ +FROM ghcr.io/pulumi/devcontainer:latest + +# Add any additional packages and customization for your project here. \ No newline at end of file diff --git a/.devcontainer/devcontainer/devcontainer.json b/.devcontainer/devcontainer/devcontainer.json new file mode 100644 index 0000000..4965b35 --- /dev/null +++ b/.devcontainer/devcontainer/devcontainer.json @@ -0,0 +1,80 @@ +// Reference: +// - https://containers.dev/features +// - https://containers.dev/implementors/features +// - https://containers.dev/implementors/json_reference +// - https://code.visualstudio.com/docs/getstarted/settings +{ + "name": "pulumi", + "dockerFile": "Dockerfile", + "customizations": { + "vscode": { + "settings": { + // https://github.com/VSCodeVim/Vim + "vim.disableExtension": true, + "vim.easymotion": true, + "vim.incsearch": true, + "vim.useSystemClipboard": true, + "vim.useCtrlKeys": true, + "vim.hlsearch": true, + "vim.insertModeKeyBindings": [ + { + "before": ["j", "j"], + "after": [""] + } + ], + "vim.handleKeys": { + "": false, + "": false + }, + "extensions.experimental.affinity": { + "vscodevim.vim": 1 + }, + "go.testTags": "all", + "go.buildTags": "all", + "editor.minimap.enabled": false, + "editor.lineNumbers": "relative", + "editor.quickSuggestionsDelay": 0, + "editor.suggestSelection": "first", + "editor.snippetSuggestions": "top", + "editor.gotoLocation.multipleReferences": "goto", + "editor.gotoLocation.multipleDefinitions": "goto", + "editor.gotoLocation.multipleDeclarations": "goto", + "editor.gotoLocation.multipleImplementations": "goto", + "editor.gotoLocation.multipleTypeDefinitions": "goto", + "editor.terminal.integrated.shell.linux": "/usr/bin/bash", + "terminal.integrated.shell.linux": "/usr/bin/bash", + "terminal.integrated.sendKeybindingsToShell": true, + "workbench.colorTheme": "Dracula Soft", + "explorer.openEditors.visible": 1, + "files.trimTrailingWhitespace": true, + "files.trimFinalNewlines": true + }, + "extensions": [ + "golang.go", + "vscodevim.vim", + "github.copilot", + "vscodevim.vim", + "ms-python.python", + "redhat.vscode-yaml", + "esbenp.prettier-vscode", + "ms-vsliveshare.vsliveshare", + "ms-azuretools.vscode-docker", + "github.vscode-github-actions", + "ms-vscode.vscode-typescript-next", + "github.vscode-pull-request-github", + "ms-vscode-remote.remote-containers", + "visualstudioexptteam.vscodeintellicode", + "bierner.markdown-preview-github-styles" + ] + } + }, + "features": { + "ghcr.io/devcontainers/features/docker-outside-of-docker:1": {} + }, + "mounts": ["source=dind-var-lib-docker,target=/var/lib/docker,type=volume"], + "remoteUser": "vscode", + "overrideCommand": false, + "runArgs": ["--init", "--privileged", "--network=host"], + "postCreateCommand": "sudo chown $USER /workspaces/* 2>/dev/null || true; direnv allow 2>/dev/null || true", + "forwardPorts": [1313, 2222, 6000, 7681, 8080] +} diff --git a/.devcontainer/devcontainer/extra/Dockerfile b/.devcontainer/devcontainer/extra/Dockerfile new file mode 100644 index 0000000..4d4f614 --- /dev/null +++ b/.devcontainer/devcontainer/extra/Dockerfile @@ -0,0 +1,185 @@ +FROM ghcr.io/pulumi/devcontainer:latest + +################################################################################## +# Add any additional packages and customization for your project here. +################################################################################## + +################################################################################## +# Install ttyd +# - https://tsl0922.github.io/ttyd +# - https://github.com/tsl0922/ttyd +RUN echo \ +&& export NAME=ttyd \ +&& export TEST="${NAME} --version" \ +&& export REPOSITORY="tsl0922/ttyd" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH=$(uname -m | awk '{ if ($1 == "x86_64") print "x86_64"; else if ($1 == "aarch64" || $1 == "arm64") print "aarch64"; else print "unknown" }') \ +&& export PKG="${NAME}.${ARCH}" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}/${PKG}" \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} --output /tmp/${NAME} \ +&& sudo ${INSTALL} /tmp/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo + +# - TTYD +EXPOSE 7681 + +################################################################################## +# Install k9s CLI +# - https://k9scli.io +# - https://github.com/derailed/k9s +RUN echo \ +&& export NAME=k9s \ +&& export TEST="${NAME} version" \ +&& export REPOSITORY="derailed/k9s" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH=$(uname -m | awk '{ if ($1 == "x86_64") print "amd64"; else if ($1 == "aarch64" || $1 == "arm64") print "arm64"; else print "unknown" }') \ +&& export PKG="${NAME}_Linux_${ARCH}.tar.gz" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}/${PKG}" \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} | sudo tar xzvf - --directory /tmp ${NAME} \ +&& sudo ${INSTALL} /tmp/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo + +################################################################################## +# Insall Cilium CLI +# - https://cilium.io +# - https://github.com/cilium/cilium-cli +RUN echo \ +&& export NAME=cilium \ +&& export TEST="${NAME} version --client" \ +&& export REPOSITORY="cilium/cilium-cli" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH=$(uname -m | awk '{ if ($1 == "x86_64") print "amd64"; else if ($1 == "aarch64" || $1 == "arm64") print "arm64"; else print "unknown" }') \ +&& export PKG="${NAME}-linux-${ARCH}.tar.gz" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}"/${PKG} \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} | tar xzvf - --directory /tmp ${NAME} \ +&& sudo ${INSTALL} /tmp/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo + +################################################################################## +# Insall istioctl +# - https://istio.io +# - https://github.com/istio/istio +# - https://github.com/istio/istio/releases/download/1.20.2/istio-1.20.2-linux-arm64.tar.gz +RUN echo \ +&& export NAME=istioctl \ +&& export TEST="${NAME} version --short 2>/dev/null" \ +&& export REPOSITORY="istio/istio" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH=$(uname -m | awk '{ if ($1 == "x86_64") print "amd64"; else if ($1 == "aarch64" || $1 == "arm64") print "arm64"; else print "unknown" }') \ +&& export PKG="istio-${VERSION}-linux-${ARCH}.tar.gz" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}/${PKG}" \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} | tar xzvf - --directory /tmp istio-${VERSION}/bin/${NAME} \ +&& sudo ${INSTALL} /tmp/istio-${VERSION}/bin/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo + +################################################################################## +# Install clusterctl +RUN echo \ +&& export NAME=clusterctl \ +&& export TEST="${NAME} version" \ +&& export REPOSITORY="kubernetes-sigs/cluster-api" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH=$(uname -m | awk '{ if ($1 == "x86_64") print "amd64"; else if ($1 == "aarch64" || $1 == "arm64") print "arm64"; else print "unknown" }') \ +&& export PKG="${NAME}-linux-${ARCH}" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}/${PKG}" \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} --output /tmp/${NAME} \ +&& sudo ${INSTALL} /tmp/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo + +################################################################################## +# Install talosctl +RUN echo \ +&& export NAME=talosctl \ +&& export TEST="${NAME} version --client" \ +&& export REPOSITORY="siderolabs/talos" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH="$(uname -m | awk '{ if ($1 == "x86_64") print "amd64"; else if ($1 == "aarch64" || $1 == "arm64") print "arm64"; else print "unknown" }')" \ +&& export PKG="${NAME}-linux-${ARCH}" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}/${PKG}" \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} --output /tmp/${NAME} \ +&& sudo ${INSTALL} /tmp/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo + +################################################################################## +# Install virtctl +RUN echo \ +&& export NAME=virtctl \ +&& export TEST="${NAME} version --client" \ +&& export REPOSITORY="kubevirt/kubevirt" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH="$(uname -m | awk '{ if ($1 == "x86_64") print "amd64"; else if ($1 == "aarch64" || $1 == "arm64") print "arm64"; else print "unknown" }')" \ +&& export PKG="${NAME}-${VERSION}-linux-${ARCH}" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}/${PKG}" \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} --output /tmp/${NAME} \ +&& sudo ${INSTALL} /tmp/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo diff --git a/.devcontainer/devcontainer/extra/devcontainer.json b/.devcontainer/devcontainer/extra/devcontainer.json new file mode 100644 index 0000000..f30d1fd --- /dev/null +++ b/.devcontainer/devcontainer/extra/devcontainer.json @@ -0,0 +1,80 @@ +// Reference: +// - https://containers.dev/features +// - https://containers.dev/implementors/features +// - https://containers.dev/implementors/json_reference +// - https://code.visualstudio.com/docs/getstarted/settings +{ + "name": "pulumi/devcontainer", + "dockerFile": "Dockerfile", + "customizations": { + "vscode": { + "settings": { + // https://github.com/VSCodeVim/Vim + "vim.disableExtension": true, + "vim.easymotion": true, + "vim.incsearch": true, + "vim.useSystemClipboard": true, + "vim.useCtrlKeys": true, + "vim.hlsearch": true, + "vim.insertModeKeyBindings": [ + { + "before": ["j", "j"], + "after": [""] + } + ], + "vim.handleKeys": { + "": false, + "": false + }, + "extensions.experimental.affinity": { + "vscodevim.vim": 1 + }, + "go.testTags": "all", + "go.buildTags": "all", + "editor.minimap.enabled": false, + "editor.lineNumbers": "relative", + "editor.quickSuggestionsDelay": 0, + "editor.suggestSelection": "first", + "editor.snippetSuggestions": "top", + "editor.gotoLocation.multipleReferences": "goto", + "editor.gotoLocation.multipleDefinitions": "goto", + "editor.gotoLocation.multipleDeclarations": "goto", + "editor.gotoLocation.multipleImplementations": "goto", + "editor.gotoLocation.multipleTypeDefinitions": "goto", + "editor.terminal.integrated.shell.linux": "/usr/bin/bash", + "terminal.integrated.shell.linux": "/usr/bin/bash", + "terminal.integrated.sendKeybindingsToShell": true, + "workbench.colorTheme": "Dracula Soft", + "explorer.openEditors.visible": 1, + "files.trimTrailingWhitespace": true, + "files.trimFinalNewlines": true + }, + "extensions": [ + "golang.go", + "vscodevim.vim", + "github.copilot", + "vscodevim.vim", + "ms-python.python", + "redhat.vscode-yaml", + "esbenp.prettier-vscode", + "ms-vsliveshare.vsliveshare", + "ms-azuretools.vscode-docker", + "github.vscode-github-actions", + "ms-vscode.vscode-typescript-next", + "github.vscode-pull-request-github", + "ms-vscode-remote.remote-containers", + "visualstudioexptteam.vscodeintellicode", + "bierner.markdown-preview-github-styles" + ] + } + }, + "features": { + "ghcr.io/devcontainers/features/docker-outside-of-docker:1": {} + }, + "remoteUser": "vscode", + "forwardPorts": [1313, 2222, 6000, 7681, 8080], + "postCreateCommand": "sudo chown $USER /workspaces/* 2>/dev/null || true; direnv allow 2>/dev/null || true", + "mounts": ["source=dind-var-lib-docker,target=/var/lib/docker,type=volume"], + "runArgs": ["--init", "--privileged", "--network=host"], + "overrideCommand": false +} diff --git a/.devcontainer/devcontainer/kind/devcontainer.json b/.devcontainer/devcontainer/kind/devcontainer.json new file mode 100644 index 0000000..50720f7 --- /dev/null +++ b/.devcontainer/devcontainer/kind/devcontainer.json @@ -0,0 +1,80 @@ +// Reference: +// - https://containers.dev/features +// - https://containers.dev/implementors/features +// - https://containers.dev/implementors/json_reference +// - https://code.visualstudio.com/docs/getstarted/settings +{ + "name": "pulumi/devcontainer", + "dockerFile": "Dockerfile", + "customizations": { + "vscode": { + "settings": { + // https://github.com/VSCodeVim/Vim + "vim.disableExtension": true, + "vim.easymotion": true, + "vim.incsearch": true, + "vim.useSystemClipboard": true, + "vim.useCtrlKeys": true, + "vim.hlsearch": true, + "vim.insertModeKeyBindings": [ + { + "before": ["j", "j"], + "after": [""] + } + ], + "vim.handleKeys": { + "": false, + "": false + }, + "extensions.experimental.affinity": { + "vscodevim.vim": 1 + }, + "go.testTags": "all", + "go.buildTags": "all", + "editor.minimap.enabled": false, + "editor.lineNumbers": "relative", + "editor.quickSuggestionsDelay": 0, + "editor.suggestSelection": "first", + "editor.snippetSuggestions": "top", + "editor.gotoLocation.multipleReferences": "goto", + "editor.gotoLocation.multipleDefinitions": "goto", + "editor.gotoLocation.multipleDeclarations": "goto", + "editor.gotoLocation.multipleImplementations": "goto", + "editor.gotoLocation.multipleTypeDefinitions": "goto", + "editor.terminal.integrated.shell.linux": "/usr/bin/bash", + "terminal.integrated.shell.linux": "/usr/bin/bash", + "terminal.integrated.sendKeybindingsToShell": true, + "workbench.colorTheme": "Dracula Soft", + "explorer.openEditors.visible": 1, + "files.trimTrailingWhitespace": true, + "files.trimFinalNewlines": true + }, + "extensions": [ + "golang.go", + "vscodevim.vim", + "github.copilot", + "vscodevim.vim", + "ms-python.python", + "redhat.vscode-yaml", + "esbenp.prettier-vscode", + "ms-vsliveshare.vsliveshare", + "ms-azuretools.vscode-docker", + "github.vscode-github-actions", + "ms-vscode.vscode-typescript-next", + "github.vscode-pull-request-github", + "ms-vscode-remote.remote-containers", + "visualstudioexptteam.vscodeintellicode", + "bierner.markdown-preview-github-styles" + ] + } + }, + "features": { + "ghcr.io/devcontainers/features/docker-outside-of-docker:1": {} + }, + "mounts": ["source=dind-var-lib-docker,target=/var/lib/docker,type=volume"], + "remoteUser": "vscode", + "forwardPorts": [1313, 2222, 6000, 7681, 8080], + "postCreateCommand": "sudo chown $USER /workspaces/* 2>/dev/null || true; direnv allow 2>/dev/null || true", + "runArgs": ["--init", "--privileged", "--network=host"], + "overrideCommand": false +} diff --git a/.devcontainer/extra/Dockerfile b/.devcontainer/extra/Dockerfile new file mode 100644 index 0000000..4d4f614 --- /dev/null +++ b/.devcontainer/extra/Dockerfile @@ -0,0 +1,185 @@ +FROM ghcr.io/pulumi/devcontainer:latest + +################################################################################## +# Add any additional packages and customization for your project here. +################################################################################## + +################################################################################## +# Install ttyd +# - https://tsl0922.github.io/ttyd +# - https://github.com/tsl0922/ttyd +RUN echo \ +&& export NAME=ttyd \ +&& export TEST="${NAME} --version" \ +&& export REPOSITORY="tsl0922/ttyd" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH=$(uname -m | awk '{ if ($1 == "x86_64") print "x86_64"; else if ($1 == "aarch64" || $1 == "arm64") print "aarch64"; else print "unknown" }') \ +&& export PKG="${NAME}.${ARCH}" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}/${PKG}" \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} --output /tmp/${NAME} \ +&& sudo ${INSTALL} /tmp/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo + +# - TTYD +EXPOSE 7681 + +################################################################################## +# Install k9s CLI +# - https://k9scli.io +# - https://github.com/derailed/k9s +RUN echo \ +&& export NAME=k9s \ +&& export TEST="${NAME} version" \ +&& export REPOSITORY="derailed/k9s" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH=$(uname -m | awk '{ if ($1 == "x86_64") print "amd64"; else if ($1 == "aarch64" || $1 == "arm64") print "arm64"; else print "unknown" }') \ +&& export PKG="${NAME}_Linux_${ARCH}.tar.gz" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}/${PKG}" \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} | sudo tar xzvf - --directory /tmp ${NAME} \ +&& sudo ${INSTALL} /tmp/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo + +################################################################################## +# Insall Cilium CLI +# - https://cilium.io +# - https://github.com/cilium/cilium-cli +RUN echo \ +&& export NAME=cilium \ +&& export TEST="${NAME} version --client" \ +&& export REPOSITORY="cilium/cilium-cli" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH=$(uname -m | awk '{ if ($1 == "x86_64") print "amd64"; else if ($1 == "aarch64" || $1 == "arm64") print "arm64"; else print "unknown" }') \ +&& export PKG="${NAME}-linux-${ARCH}.tar.gz" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}"/${PKG} \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} | tar xzvf - --directory /tmp ${NAME} \ +&& sudo ${INSTALL} /tmp/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo + +################################################################################## +# Insall istioctl +# - https://istio.io +# - https://github.com/istio/istio +# - https://github.com/istio/istio/releases/download/1.20.2/istio-1.20.2-linux-arm64.tar.gz +RUN echo \ +&& export NAME=istioctl \ +&& export TEST="${NAME} version --short 2>/dev/null" \ +&& export REPOSITORY="istio/istio" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH=$(uname -m | awk '{ if ($1 == "x86_64") print "amd64"; else if ($1 == "aarch64" || $1 == "arm64") print "arm64"; else print "unknown" }') \ +&& export PKG="istio-${VERSION}-linux-${ARCH}.tar.gz" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}/${PKG}" \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} | tar xzvf - --directory /tmp istio-${VERSION}/bin/${NAME} \ +&& sudo ${INSTALL} /tmp/istio-${VERSION}/bin/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo + +################################################################################## +# Install clusterctl +RUN echo \ +&& export NAME=clusterctl \ +&& export TEST="${NAME} version" \ +&& export REPOSITORY="kubernetes-sigs/cluster-api" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH=$(uname -m | awk '{ if ($1 == "x86_64") print "amd64"; else if ($1 == "aarch64" || $1 == "arm64") print "arm64"; else print "unknown" }') \ +&& export PKG="${NAME}-linux-${ARCH}" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}/${PKG}" \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} --output /tmp/${NAME} \ +&& sudo ${INSTALL} /tmp/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo + +################################################################################## +# Install talosctl +RUN echo \ +&& export NAME=talosctl \ +&& export TEST="${NAME} version --client" \ +&& export REPOSITORY="siderolabs/talos" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH="$(uname -m | awk '{ if ($1 == "x86_64") print "amd64"; else if ($1 == "aarch64" || $1 == "arm64") print "arm64"; else print "unknown" }')" \ +&& export PKG="${NAME}-linux-${ARCH}" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}/${PKG}" \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} --output /tmp/${NAME} \ +&& sudo ${INSTALL} /tmp/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo + +################################################################################## +# Install virtctl +RUN echo \ +&& export NAME=virtctl \ +&& export TEST="${NAME} version --client" \ +&& export REPOSITORY="kubevirt/kubevirt" \ +&& export VERSION="$(${curl} https://api.github.com/repos/${REPOSITORY}/releases/latest | jq --raw-output .tag_name)" \ +&& export ARCH="$(uname -m | awk '{ if ($1 == "x86_64") print "amd64"; else if ($1 == "aarch64" || $1 == "arm64") print "arm64"; else print "unknown" }')" \ +&& export PKG="${NAME}-${VERSION}-linux-${ARCH}" \ +&& export URL="https://github.com/${REPOSITORY}/releases/download/${VERSION}/${PKG}" \ +&& echo "---------------------------------------------------------"\ +&& echo "INFO[${NAME}] Installed:" \ +&& echo "INFO[${NAME}] Command: ${NAME}" \ +&& echo "INFO[${NAME}] Package: ${PKG}" \ +&& echo "INFO[${NAME}] Latest Release: ${VERSION}" \ +&& echo "INFO[${NAME}] Architecture: ${ARCH}" \ +&& echo "INFO[${NAME}] Source: ${URL}" \ +&& echo "---------------------------------------------------------"\ +&& ${curl} ${URL} --output /tmp/${NAME} \ +&& sudo ${INSTALL} /tmp/${NAME} ${BIN}/${NAME} \ +&& ${dir_clean} \ +&& ${TEST} \ +&& echo diff --git a/.devcontainer/extra/devcontainer.json b/.devcontainer/extra/devcontainer.json new file mode 100644 index 0000000..f30d1fd --- /dev/null +++ b/.devcontainer/extra/devcontainer.json @@ -0,0 +1,80 @@ +// Reference: +// - https://containers.dev/features +// - https://containers.dev/implementors/features +// - https://containers.dev/implementors/json_reference +// - https://code.visualstudio.com/docs/getstarted/settings +{ + "name": "pulumi/devcontainer", + "dockerFile": "Dockerfile", + "customizations": { + "vscode": { + "settings": { + // https://github.com/VSCodeVim/Vim + "vim.disableExtension": true, + "vim.easymotion": true, + "vim.incsearch": true, + "vim.useSystemClipboard": true, + "vim.useCtrlKeys": true, + "vim.hlsearch": true, + "vim.insertModeKeyBindings": [ + { + "before": ["j", "j"], + "after": [""] + } + ], + "vim.handleKeys": { + "": false, + "": false + }, + "extensions.experimental.affinity": { + "vscodevim.vim": 1 + }, + "go.testTags": "all", + "go.buildTags": "all", + "editor.minimap.enabled": false, + "editor.lineNumbers": "relative", + "editor.quickSuggestionsDelay": 0, + "editor.suggestSelection": "first", + "editor.snippetSuggestions": "top", + "editor.gotoLocation.multipleReferences": "goto", + "editor.gotoLocation.multipleDefinitions": "goto", + "editor.gotoLocation.multipleDeclarations": "goto", + "editor.gotoLocation.multipleImplementations": "goto", + "editor.gotoLocation.multipleTypeDefinitions": "goto", + "editor.terminal.integrated.shell.linux": "/usr/bin/bash", + "terminal.integrated.shell.linux": "/usr/bin/bash", + "terminal.integrated.sendKeybindingsToShell": true, + "workbench.colorTheme": "Dracula Soft", + "explorer.openEditors.visible": 1, + "files.trimTrailingWhitespace": true, + "files.trimFinalNewlines": true + }, + "extensions": [ + "golang.go", + "vscodevim.vim", + "github.copilot", + "vscodevim.vim", + "ms-python.python", + "redhat.vscode-yaml", + "esbenp.prettier-vscode", + "ms-vsliveshare.vsliveshare", + "ms-azuretools.vscode-docker", + "github.vscode-github-actions", + "ms-vscode.vscode-typescript-next", + "github.vscode-pull-request-github", + "ms-vscode-remote.remote-containers", + "visualstudioexptteam.vscodeintellicode", + "bierner.markdown-preview-github-styles" + ] + } + }, + "features": { + "ghcr.io/devcontainers/features/docker-outside-of-docker:1": {} + }, + "remoteUser": "vscode", + "forwardPorts": [1313, 2222, 6000, 7681, 8080], + "postCreateCommand": "sudo chown $USER /workspaces/* 2>/dev/null || true; direnv allow 2>/dev/null || true", + "mounts": ["source=dind-var-lib-docker,target=/var/lib/docker,type=volume"], + "runArgs": ["--init", "--privileged", "--network=host"], + "overrideCommand": false +} diff --git a/.devcontainer/kind/devcontainer.json b/.devcontainer/kind/devcontainer.json new file mode 100644 index 0000000..50720f7 --- /dev/null +++ b/.devcontainer/kind/devcontainer.json @@ -0,0 +1,80 @@ +// Reference: +// - https://containers.dev/features +// - https://containers.dev/implementors/features +// - https://containers.dev/implementors/json_reference +// - https://code.visualstudio.com/docs/getstarted/settings +{ + "name": "pulumi/devcontainer", + "dockerFile": "Dockerfile", + "customizations": { + "vscode": { + "settings": { + // https://github.com/VSCodeVim/Vim + "vim.disableExtension": true, + "vim.easymotion": true, + "vim.incsearch": true, + "vim.useSystemClipboard": true, + "vim.useCtrlKeys": true, + "vim.hlsearch": true, + "vim.insertModeKeyBindings": [ + { + "before": ["j", "j"], + "after": [""] + } + ], + "vim.handleKeys": { + "": false, + "": false + }, + "extensions.experimental.affinity": { + "vscodevim.vim": 1 + }, + "go.testTags": "all", + "go.buildTags": "all", + "editor.minimap.enabled": false, + "editor.lineNumbers": "relative", + "editor.quickSuggestionsDelay": 0, + "editor.suggestSelection": "first", + "editor.snippetSuggestions": "top", + "editor.gotoLocation.multipleReferences": "goto", + "editor.gotoLocation.multipleDefinitions": "goto", + "editor.gotoLocation.multipleDeclarations": "goto", + "editor.gotoLocation.multipleImplementations": "goto", + "editor.gotoLocation.multipleTypeDefinitions": "goto", + "editor.terminal.integrated.shell.linux": "/usr/bin/bash", + "terminal.integrated.shell.linux": "/usr/bin/bash", + "terminal.integrated.sendKeybindingsToShell": true, + "workbench.colorTheme": "Dracula Soft", + "explorer.openEditors.visible": 1, + "files.trimTrailingWhitespace": true, + "files.trimFinalNewlines": true + }, + "extensions": [ + "golang.go", + "vscodevim.vim", + "github.copilot", + "vscodevim.vim", + "ms-python.python", + "redhat.vscode-yaml", + "esbenp.prettier-vscode", + "ms-vsliveshare.vsliveshare", + "ms-azuretools.vscode-docker", + "github.vscode-github-actions", + "ms-vscode.vscode-typescript-next", + "github.vscode-pull-request-github", + "ms-vscode-remote.remote-containers", + "visualstudioexptteam.vscodeintellicode", + "bierner.markdown-preview-github-styles" + ] + } + }, + "features": { + "ghcr.io/devcontainers/features/docker-outside-of-docker:1": {} + }, + "mounts": ["source=dind-var-lib-docker,target=/var/lib/docker,type=volume"], + "remoteUser": "vscode", + "forwardPorts": [1313, 2222, 6000, 7681, 8080], + "postCreateCommand": "sudo chown $USER /workspaces/* 2>/dev/null || true; direnv allow 2>/dev/null || true", + "runArgs": ["--init", "--privileged", "--network=host"], + "overrideCommand": false +} diff --git a/.frontmatter/database/taxonomyDb.json b/.frontmatter/database/taxonomyDb.json deleted file mode 100644 index 9e26dfe..0000000 --- a/.frontmatter/database/taxonomyDb.json +++ /dev/null @@ -1 +0,0 @@ -{} \ No newline at end of file diff --git a/.github/devcontainer b/.github/devcontainer new file mode 160000 index 0000000..84e701c --- /dev/null +++ b/.github/devcontainer @@ -0,0 +1 @@ +Subproject commit 84e701c461bcfcd9adb76ad949dd9803d20fb238 diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..25a840b --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule ".github/devcontainer"] + path = .github/devcontainer + url = https://github.com/pulumi/devcontainer diff --git a/.gitpod.yml b/.gitpod.yml deleted file mode 100644 index 07fdbf0..0000000 --- a/.gitpod.yml +++ /dev/null @@ -1 +0,0 @@ -image: ghcr.io/pulumi/devcontainer \ No newline at end of file diff --git a/Makefile b/Makefile index cfaadbe..c059b29 100644 --- a/Makefile +++ b/Makefile @@ -87,7 +87,7 @@ kind: devcontainer:: git submodule update --init --recursive .github/devcontainer git submodule update --remote --merge .github/devcontainer - cp .devcontainer/devcontainer.json .devcontainer.json + rsync -av .github/devcontainer/devcontainer/* .devcontainer # --- Default Command --- # Default command when running 'make' without arguments