Commit f01a1109 authored by Marcia Ramos's avatar Marcia Ramos

Merge branch 'nagyv-gitlab-master-patch-86215' into 'master'

Indentation and generated path fix

See merge request gitlab-org/gitlab!64686
parents 52cdb26c 5974f6f6
...@@ -30,30 +30,29 @@ To create the Tunnel: ...@@ -30,30 +30,29 @@ To create the Tunnel:
.kubectl_config: &kubectl_config .kubectl_config: &kubectl_config
- | - |
cat << EOF > "$HOME/agent_config.yaml" cat << EOF > "$CI_PROJECT_DIR/.kubeconfig.agent.yaml"
apiVersion: v1 apiVersion: v1
kind: Config kind: Config
clusters: clusters:
- cluster: - cluster:
server: https://kas.gitlab.com/k8s-proxy server: https://kas.gitlab.com/k8s-proxy
name: agent name: agent
users: users:
- name: agent - name: agent
user: user:
token: "ci:$AGENT_ID:$CI_JOB_TOKEN" token: "ci:$AGENT_ID:$CI_JOB_TOKEN"
contexts: contexts:
- context: - context:
cluster: agent cluster: agent
user: agent user: agent
name: agent name: agent
current-context: agent current-context: agent
EOF EOF
- export KUBECONFIG="$KUBECONFIG:$HOME/agent_config.yaml"
deploy: deploy:
script: script:
- *kubectl_config - *kubectl_config
- kubectl get pods - kubectl --kubeconfig="$CI_PROJECT_DIR/.kubeconfig.agent.yaml" get pods
``` ```
1. Execute `kubectl` commands directly against your cluster with this CI/CD job you just created. 1. Execute `kubectl` commands directly against your cluster with this CI/CD job you just created.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment