Skip to content
This repository has been archived by the owner on Nov 20, 2021. It is now read-only.

Commit

Permalink
cinder: update mapi and mapd
Browse files Browse the repository at this point in the history
  • Loading branch information
Kyle Travis authored and ChrisRx committed Oct 21, 2020
1 parent cfa1997 commit b343932
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 15 deletions.
14 changes: 7 additions & 7 deletions build/images/node/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ KUBERNETES_VERSION := 1.18.5
CHARTS_DIR := $(PWD)/charts
CILIUM_VERSION := 1.8.1
LOCAL_PATH_PROVISIONER_VERSION := 0.0.12
MACHINE_API_VERSION := 0.1.2
MACHINE_API_PROVIDER_DOCKER_VERSION := 0.1.2
MACHINE_API_VERSION := 1.0.1
MACHINE_API_PROVIDER_DOCKER_VERSION := 1.0.2

charts/*.tgz:
mkdir -p $(CHARTS_DIR)
Expand All @@ -44,12 +44,8 @@ charts/*.tgz:
helm repo update
helm pull cilium/cilium --version $(CILIUM_VERSION) -d $(CHARTS_DIR)
helm pull criticalstack/local-path-provisioner --version $(LOCAL_PATH_PROVISIONER_VERSION) -d $(CHARTS_DIR)
helm pull criticalstack/machine-api --version $(MACHINE_API_VERSION) -d $(CHARTS_DIR)
helm pull criticalstack/machine-api-provider-docker --version $(MACHINE_API_PROVIDER_DOCKER_VERSION) -d $(CHARTS_DIR)
mv $(CHARTS_DIR)/cilium-$(CILIUM_VERSION).tgz $(CHARTS_DIR)/cilium.tgz
mv $(CHARTS_DIR)/local-path-provisioner-$(LOCAL_PATH_PROVISIONER_VERSION).tgz $(CHARTS_DIR)/local-path-provisioner.tgz
mv $(CHARTS_DIR)/machine-api-$(MACHINE_API_VERSION).tgz $(CHARTS_DIR)/machine-api.tgz
mv $(CHARTS_DIR)/machine-api-provider-docker-$(MACHINE_API_PROVIDER_DOCKER_VERSION).tgz $(CHARTS_DIR)/machine-api-provider-docker.tgz

build/*.tar:
mkdir -p $(BUILD_DIR)
Expand All @@ -67,7 +63,11 @@ build: clean $(CRIT) $(CINDER) charts/*.tgz build/*.tar ## build cinder docker i
docker exec $(BUILD_CONTAINER_NAME) bash -c 'mkdir -p /cinder'
docker cp ./charts $(BUILD_CONTAINER_NAME):/cinder/charts
docker cp ./scripts $(BUILD_CONTAINER_NAME):/cinder/scripts
docker exec -e KUBERNETES_VERSION=$(KUBERNETES_VERSION) $(BUILD_CONTAINER_NAME) bash -c /cinder/scripts/build.sh
docker exec \
-e KUBERNETES_VERSION=$(KUBERNETES_VERSION) \
-e MACHINE_API_VERSION=$(MACHINE_API_VERSION) \
-e MACHINE_API_PROVIDER_DOCKER_VERSION=$(MACHINE_API_PROVIDER_DOCKER_VERSION) \
$(BUILD_CONTAINER_NAME) bash -c /cinder/scripts/build.sh
for f in $$(find files/ -type f)
do
docker cp $$f $(BUILD_CONTAINER_NAME):$${f##*files/}
Expand Down
3 changes: 3 additions & 0 deletions build/images/node/scripts/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ curl -L https://storage.googleapis.com/kubernetes-release/release/v${KUBERNETES_
chmod +x /usr/bin/kubelet
echo "KUBELET_EXTRA_ARGS=--fail-swap-on=false" >> /etc/default/kubelet
curl https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3 | bash
mkdir -p /cinder/manifests
curl -L https://github.com/criticalstack/machine-api/releases/download/v${MACHINE_API_VERSION}/machine-api.yaml -o /cinder/manifests/machine-api.yaml
curl -L https://github.com/criticalstack/machine-api-provider-docker/releases/download/v${MACHINE_API_PROVIDER_DOCKER_VERSION}/machine-api-provider-docker.yaml -o /cinder/manifests/machine-api-provider-docker.yaml
curl -LO https://download.docker.com/linux/static/stable/x86_64/docker-19.03.1.tgz
tar zxvf docker-19.03.1.tgz --strip 1 -C /usr/bin docker/docker
rm docker-19.03.1.tgz
Expand Down
5 changes: 2 additions & 3 deletions build/images/node/scripts/install-machine-api.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#!/bin/bash

kubectl create namespace mapi-system
helm install machine-api /cinder/charts/machine-api.tgz --namespace mapi-system \
--set externalReadyWait=1s
kubectl apply -n mapi-system -f /cinder/manifests/machine-api.yaml
kubectl create namespace mapd-system
helm install machine-api-provider-docker /cinder/charts/machine-api-provider-docker.tgz --namespace mapd-system
kubectl apply -n mapd-system -f /cinder/manifests/machine-api-provider-docker.yaml
10 changes: 5 additions & 5 deletions internal/cinder/config/constants/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ import (
)

const (
DefaultNodeImage = "criticalstack/cinder:v1.0.3"
DefaultNodeImage = "criticalstack/cinder:v1"
DefaultNetwork = "cinder"
KubernetesVersion = "1.18.5"

DefaultMachineAPIVersion = "0.1.2"
DefaultMachineAPIProviderDockerVersion = "0.1.2"
DefaultMachineAPIVersion = "1.0.1"
DefaultMachineAPIProviderDockerVersion = "1.0.2"
DefaultKubeRBACProxyVersion = "0.5.0"
DefaultCiliumVersion = "1.8.1"
DefaultCiliumStartupScriptVersion = "af2a99046eca96c0138551393b21a5c044c7fe79"
Expand All @@ -33,8 +33,8 @@ func GetImages() map[string]string {
"coredns": fmt.Sprintf("%s:%s", constants.CoreDNSImage, constants.DefaultCoreDNSVersion),
"bootstrap-server": fmt.Sprintf("%s:v%s", constants.CritBootstrapServerImage, constants.DefaultBootstrapServerVersion),
"healthcheck-proxy": fmt.Sprintf("%s:v%s", constants.CritHealthCheckProxyImage, constants.DefaultHealthcheckProxyVersion),
"machine-api": fmt.Sprintf("cscr.io/criticalstack/machine-api:v%s", DefaultMachineAPIVersion),
"machine-api-provider-docker": fmt.Sprintf("cscr.io/criticalstack/machine-api-provider-docker:v%s", DefaultMachineAPIProviderDockerVersion),
"machine-api": fmt.Sprintf("docker.io/criticalstack/machine-api:v%s", DefaultMachineAPIVersion),
"machine-api-provider-docker": fmt.Sprintf("docker.io/criticalstack/machine-api-provider-docker:v%s", DefaultMachineAPIProviderDockerVersion),
"kube-rbac-proxy": fmt.Sprintf("gcr.io/kubebuilder/kube-rbac-proxy:v%s", DefaultKubeRBACProxyVersion),
"cilium": fmt.Sprintf("docker.io/cilium/cilium:v%s", DefaultCiliumVersion),
"cilium-operator-generic": fmt.Sprintf("docker.io/cilium/operator-generic:v%s", DefaultCiliumVersion),
Expand Down

0 comments on commit b343932

Please sign in to comment.