Test github action with kubeconfig #15
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
on: | |
pull_request: | |
branches: | |
- main | |
jobs: | |
preview: | |
runs-on: ubuntu-latest | |
container: okteto/okteto:latest | |
steps: | |
- name: Context | |
uses: okteto/context@latest | |
with: | |
token: ${{ secrets.OKTETO_TOKEN }} | |
url: ${{ secrets.OKTETO_URL }} | |
env: | |
KUBECONFIG: /github/home/.kube/config | |
- name: Set kubeconfig | |
# run: cd ${RUNNER_TEMP}/_github_home/.kube && ls -la ${RUNNER_TEMP}/_github_home/.kube | |
run: cd /github/home/.kube/ && ls -la /github/home/.kube/ | |
- name: List namespaces | |
run: kubectl get sa | |
env: | |
KUBECONFIG: /github/home/.kube/config | |
# KUBECONFIG: ${RUNNER_TEMP}/_github_home/.kube/config |