Created
September 15, 2023 15:17
-
-
Save ravilach/2e67ef670113b34a7b39b4323d1fd994 to your computer and use it in GitHub Desktop.
Get Started with Harness CLI
This file contains 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 characters
curl -LO https://github.com/harness/harness-cli/releases/download/v0.0.15-Preview/harness-v0.0.15-Preview-darwin-amd64.tar.gz | |
tar -xvf harness-v0.0.15-Preview-darwin-amd64.tar.gz | |
export PATH="$(pwd):$PATH" | |
echo 'export PATH="'$(pwd)':$PATH"' >> ~/.bash_profile | |
minikube start --memory 4g --cpus 4 | |
kubectl create namespace mygitopsns | |
helm install gitops-agent ./gitops-agent.tgz -n mygitopsns | |
kubectl --namespace mygitopsns get pods | |
NAME READY STATUS RESTARTS AGE | |
argocd-application-controller-0 0/1 ContainerCreating 0 57s | |
argocd-applicationset-controller-5c89c8c576-wwn9s 0/1 ContainerCreating 0 57s | |
argocd-redis-6fdfb99d58-c88kf 1/1 Running 0 57s | |
argocd-repo-server-5b865c755b-5vg4v 0/1 Init:0/2 0 57s | |
mygitopsagent-agent-58755856dc-22hq2 0/1 ContainerCreating 0 57s | |
export AGENT_NAME=mygitopsagent | |
harness login --api-key <your_harness_pat> --account-id <your_harness_account_idt> | |
harness gitops-repository --file guestbook/harness-gitops/repository.yml apply --agent-identifier $AGENT_NAME | |
harness gitops-cluster --file guestbook/harness-gitops/cluster.yml apply --agent-identifier $AGENT_NAME | |
harness gitops-application --file guestbook/harness-gitops/application.yml apply --agent-identifier $AGENT_NAME |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment