Created
January 8, 2020 17:40
-
-
Save NorbertFenk/2a34c6fc58cc4951d66fff08b1ddf054 to your computer and use it in GitHub Desktop.
Revisions
-
NorbertFenk created this gist
Jan 8, 2020 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,73 @@ Resources https://dzone.com/articles/install-spinnaker-with-halyard-on-kubernetes https://www.spinnaker.io/setup/install/halyard/ Steps to install spinnaker to a local dev cluster You will need a Kubernetes emulator link kind You will need to install halyard. This is a spinnaker deployment management tool. Here you can find further information about it and an installation guide: https://www.spinnaker.io/setup/install/halyard/ Follow these steps : https://www.spinnaker.io/setup/install/providers/kubernetes-v2/ ``` # First, make sure that the provider is enabled: hal config provider kubernetes enable # Start your local kubernetes cluster kind create cluster # Create namespace, we will need it and it is a good test about the cluster access kubectl create namespace spinnaker # Then add the account: CONTEXT=$(kubectl config current-context) hal config provider kubernetes account add my-k8s-v2-account \ --provider-version v2 \ --context $CONTEXT # Another command that needs to be run hal config features edit --artifacts true ``` Follow these steps to Choose an environment: https://www.spinnaker.io/setup/install/environment/ I went with the Distributed installation because I think this will fits the best later on. ``` export ACCOUNT=my-k8s-v2-account # Run the following command, using the $ACCOUNT name you created when you configured the provider hal config deploy edit --type distributed --account-name $ACCOUNT ``` From the offered storage services I chose Minio and followed this guide: https://www.spinnaker.io/setup/install/storage/minio/ ``` # Export minio secret and access keys <needs to contain letters and number> e.g.: hello1234 export MINIO_SECRET_KEY=hello1234 export MINIO_ACCESS_KEY=hello1234 # Use helm to deploy it to the kubernetes cluster. Pay attention to the "persistence.enable=false" part. This way it won't persits the configs. helm install -n spinnaker minio --set accessKey=$MINIO_ACCESS_KEY --set secretKey=$MINIO_SECRET_KEY --set persistence.enable=false stable/minio # Given that Minio doesn’t support versioning objects, we need to disable it in Spinnaker. mkdir -p ~/.hal/default/profiles && echo spinnaker.s3.versioning: false > ~/.hal/default/profiles/front50-local.yml # This command will configure the halyard to be able to communicate wit the Minio storage echo $MINIO_SECRET_KEY | hal config storage s3 edit --path-style-access true --endpoint http://minio:9000 --access-key-id $MINIO_ACCESS_KEY --secret-access-key # reun this command too hal config storage edit --type s3 ``` Deploy the services and connect to them: https://www.spinnaker.io/setup/install/deploy/ ``` # List the available versions hal version list # Set the version you want to use hal config version edit --version $VERSION # Deploy the services hal deploy apply # Connect to the services TODO make it work hal deploy connect ```