Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Initial demo script using CAPI Docker provider #29

Merged
merged 2 commits into from
Nov 24, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .tool-versions
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
clusterctl 1.2.6
ginkgo 2.5.0
gojq 0.12.9
golang 1.19.3
golangci-lint 1.50.1
goreleaser 1.12.3
Expand Down
239 changes: 0 additions & 239 deletions hack/demo.sh

This file was deleted.

10 changes: 10 additions & 0 deletions hack/demo/Dockerfile.demo-node
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Copyright 2022 D2iQ, Inc. All rights reserved.
# SPDX-License-Identifier: Apache-2.0

# syntax=docker/dockerfile:1

FROM --platform=linux/${TARGETARCH} mesosphere/kind-node:v1.25.4

ARG TARGETARCH
COPY dist/shim-credential-provider_linux_${TARGETARCH}_v1/shim-credential-provider /etc/kubernetes/image-credential-provider/
COPY dist/static-credential-provider_linux_${TARGETARCH}_v1/static-credential-provider /etc/kubernetes/image-credential-provider/
8 changes: 4 additions & 4 deletions hack/airgapped-demo.sh → hack/demo/airgapped-demo.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ IFS=$'\n\t'
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
readonly SCRIPT_DIR

readonly ROOT_DIR="${SCRIPT_DIR}/.."
pushd "${SCRIPT_DIR}/../.."

readonly DEMODATA_DIR="${ROOT_DIR}/demodata"
readonly DEMODATA_DIR="demodata"
rm -rf "${DEMODATA_DIR}" && mkdir -p "${DEMODATA_DIR}"

export KIND_EXPERIMENTAL_DOCKER_NETWORK=shim-credentials-airgapped-kind-network
Expand All @@ -22,8 +22,8 @@ REGISTRY_IP=$(docker network inspect "${KIND_EXPERIMENTAL_DOCKER_NETWORK}" |
REGISTRY_PORT=5000
# Use a domain so it can be access on a Mac
REGISTRY_ADDRESS=registry-airgapped
REGISTRY_CERTS_DIR="${DEMODATA_DIR}/certs"
REGISTRY_AUTH_DIR="${DEMODATA_DIR}/auth"
REGISTRY_CERTS_DIR="$(realpath "${DEMODATA_DIR}/certs")"
REGISTRY_AUTH_DIR="$(realpath "${DEMODATA_DIR}/auth")"
REGISTRY_USERNAME=testuser
REGISTRY_PASSWORD=testpassword

Expand Down
Loading