From 31a4172d697a7e72b9ccd239810d5bb1b69c4547 Mon Sep 17 00:00:00 2001 From: Philipp Strube Date: Mon, 18 May 2020 11:47:07 +0200 Subject: [PATCH 1/2] Improve manual operations section in default README.md --- .../src/configurations/_shared/README.md | 91 ++++++++++--------- 1 file changed, 49 insertions(+), 42 deletions(-) diff --git a/quickstart/src/configurations/_shared/README.md b/quickstart/src/configurations/_shared/README.md index ee41f4ec..6640c0fe 100644 --- a/quickstart/src/configurations/_shared/README.md +++ b/quickstart/src/configurations/_shared/README.md @@ -84,48 +84,55 @@ To accelerate the developer workflow, a [development environment][6], can be run In case of the automation being unavailable, upgrades requiring manual steps or in disaster recovery scenarios run Terraform and the cloud CLI locally. Kubestack provides container images bundling all dependencies to use for both automated and manual operations. -```shell -# Build the bootstrap container -docker build -t kubestack . - -# Exec into the bootstrap container -docker run --rm -ti \ - -v `pwd`:/infra \ - # uncomment to mount the docker socket for local dev - # -v /var/run/docker.sock:/var/run/docker.sock \ - kubestack -``` - -```shell -# if you haven't before, login - -# for AWS -aws configure - -# for Azure -az login - -# for GCP -gcloud init -gcloud auth application-default login -``` - -```shell -# select the desired environment -# for ops -terraform workspace select ops - -# or for apps -terraform workspace select apps -``` - -```shell -# run terraform init -terraform init - -# run terraform commands as required, e.g. -terraform plan -``` + 1. Exec into container + + ```shell + # Build the bootstrap container + docker build -t kubestack . + + # Exec into the bootstrap container + # add docker socket mount for local dev + # -v /var/run/docker.sock:/var/run/docker.sock + docker run --rm -ti \ + -v `pwd`:/infra \ + kubestack + ``` + + 1. Authenticate providers + + Credentials are cached inside the `.user` directory. The directory is excluded from Git by the default `.gitignore`. + + ```shell + # for AWS + aws configure + + # for Azure + az login + + # for GCP + gcloud init + gcloud auth application-default login + ``` + + 1. Select desired environment + + ```shell + # for ops + terraform workspace select ops + + # or for apps + terraform workspace select apps + ``` + + 1. Run Terraform commands + + ```shell + # run terraform init + terraform init + + # run, e.g. terraform plan + terraform plan + ``` [1]: https://www.kubestack.com [2]: https://www.kubestack.com/catalog From 5768ffab9912ab75fdb98421637278b4b05d15cb Mon Sep 17 00:00:00 2001 From: Philipp Strube Date: Mon, 18 May 2020 12:26:20 +0200 Subject: [PATCH 2/2] Fix publishing starters when triggered by a tag --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 1ebe0fff..b0f475fa 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -217,7 +217,7 @@ jobs: run: | SOURCE_FILE=test-artifacts/kubestack-starter-${{ matrix.starter }}-${{ github.sha }}.zip TARGET_BUCKET=dev.quickstart.kubestack.com - if [[ GITHUB_REF = refs/tags/v* ]] + if [[ $GITHUB_REF = refs/tags/v* ]] then VERSION=$(echo $GITHUB_REF | sed -e "s#^refs/tags/##") SOURCE_FILE=test-artifacts/kubestack-starter-${{ matrix.starter }}-${VERSION}.zip