From dba192052ba98913d178be5a784439114f55060c Mon Sep 17 00:00:00 2001 From: Paul Gilber Date: Sun, 5 Nov 2023 03:06:23 +0000 Subject: [PATCH 1/2] install mysql, podman, trivy, container structure tests via features and remove from post create command --- .devcontainer/devcontainer.json | 8 ++++++++ .devcontainer/postCreateCommand.sh | 22 ---------------------- 2 files changed, 8 insertions(+), 22 deletions(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 8380b9d..598c8ec 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -27,6 +27,14 @@ }, // Install Homebrew: https://github.com/meaningful-ooo/devcontainer-features/tree/main/src/homebrew "ghcr.io/meaningful-ooo/devcontainer-features/homebrew:2": {}, + // Install Homebrew Package: https://github.com/devcontainers-contrib/features/tree/main/src/homebrew-package + "ghcr.io/devcontainers-contrib/features/homebrew-package:1": {}, + // Install MySQL (via Homebrew): http://github.com/devcontainers-contrib/features/tree/main/src/mysql-homebrew + "ghcr.io/devcontainers-contrib/features/mysql-homebrew:1": {}, + // Install Podman (via Homebrew): http://github.com/devcontainers-contrib/features/tree/main/src/podman-homebrew + "ghcr.io/devcontainers-contrib/features/podman-homebrew:1": {}, + // Install Trivy: https://github.com/itsmechlark/features/tree/main/src/trivy + "ghcr.io/itsmechlark/features/trivy:1": {}, // Install jq, yq, gojq, xq, jaq : https://github.com/eitsupi/devcontainer-features/tree/main/src/jq-likes "ghcr.io/eitsupi/devcontainer-features/jq-likes:2": { "jqVersion": "latest", diff --git a/.devcontainer/postCreateCommand.sh b/.devcontainer/postCreateCommand.sh index 46693b9..fcb00b4 100755 --- a/.devcontainer/postCreateCommand.sh +++ b/.devcontainer/postCreateCommand.sh @@ -3,25 +3,3 @@ # Specify a folder for hooks (only available for git version >= 2.9) git config core.hooksPath .githooks -# Installation of MySQL (via Homebrew) feature fails. -# Install MySQL after container creation. -# Failed feature: ghcr.io/devcontainers-contrib/features/mysql-homebrew:1 -brew install mysql - -# No available feature for installing Container Structure Test https://github.com/GoogleContainerTools/container-structure-test -brew install container-structure-test - -# Installation of Podman (via Homebrew) feature fails. -# Install Podman after container creation. -# Failed feature: ghcr.io/devcontainers-contrib/features/podman-homebrew:1 -brew install podman - -# No available feature for installing Podman Compose: https://github.com/containers/podman-compose -pip3 install podman-compose - -# No available feature for installing Aqua Security Trivy: https://github.com/aquasecurity/trivy -brew install trivy - -# No available feature for installing regclient: https://github.com/regclient/regclient -curl -L https://github.com/regclient/regclient/releases/latest/download/regctl-linux-amd64 > ${HOME}/.local/bin/regctl -chmod 755 ${HOME}/.local/bin/regctl From 5551624d5952c5d6c103b33cc0cc8e88215f2fe5 Mon Sep 17 00:00:00 2001 From: Paul Gilber Date: Sun, 5 Nov 2023 03:07:11 +0000 Subject: [PATCH 2/2] git auto create missing upstream branch --- .devcontainer/postCreateCommand.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.devcontainer/postCreateCommand.sh b/.devcontainer/postCreateCommand.sh index fcb00b4..a891754 100755 --- a/.devcontainer/postCreateCommand.sh +++ b/.devcontainer/postCreateCommand.sh @@ -3,3 +3,5 @@ # Specify a folder for hooks (only available for git version >= 2.9) git config core.hooksPath .githooks +# Auto-create missing upstream branch +git config push.autoSetupRemote true