Regression tests Cron #1224
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
name: Regression tests Cron | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: "0 0 * * *" | |
jobs: | |
k8s: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
path: tackle-ui-tests | |
ref: main | |
- name: Checkout tackle | |
uses: actions/checkout@v2 | |
with: | |
repository: konveyor/tackle | |
path: tackle | |
- name: Setup Minikube | |
uses: manusa/[email protected] | |
with: | |
minikube version: v1.18.1 | |
kubernetes version: v1.21.4 | |
start args: "--addons=registry --addons=ingress" | |
- name: Validate Minikube | |
run: minikube status | grep Running | |
- name: Validate Cluster | |
run: kubectl get nodes | |
- name: Validate enabled addon in arg | |
run: minikube addons list -o json | jq '.registry.Status' | grep enabled | |
- name: Kubectl create namespace | |
run: kubectl create ns tackle | |
- name: Deploy tackle | |
run: sleep 60s && kubectl create -f tackle/kubernetes/kubernetes-tackle.yaml -n tackle | |
- name: Verify keycloak | |
run: kubectl wait deployment/keycloak --for condition=available --timeout=-1s -n tackle | |
- name: Verify tackle-controls | |
run: kubectl wait deployment/tackle-controls --for condition=available --timeout=-1s -n tackle | |
- name: Verify tackle-application-inventory | |
run: kubectl wait deployment/tackle-application-inventory --for condition=available --timeout=-1s -n tackle | |
- name: Verify tackle-pathfinder | |
run: kubectl wait deployment/tackle-pathfinder --for condition=available --timeout=-1s -n tackle | |
- name: Verify tackle-ui | |
run: kubectl wait deployment/tackle-ui --for condition=available --timeout=-1s -n tackle | |
- name: Wait for Ingress | |
run: | | |
bash -c 'external_ip=""; | |
while [ -z $external_ip ]; | |
do echo "Waiting for end point..."; | |
external_ip=$(kubectl get ingress tackle --template="{{range .status.loadBalancer.ingress}}{{.ip}}{{end}}" -n tackle);[ -z "$external_ip" ] && | |
sleep 10; | |
done; | |
echo "End point ready:" && | |
echo $external_ip; | |
export endpoint=$external_ip; | |
echo "CYPRESS_tackleUrl=https://$external_ip" >>$GITHUB_ENV' | |
- name: Cypress run | |
uses: cypress-io/github-action@v2 | |
with: | |
working-directory: tackle-ui-tests | |
start: npx echo "Starting Minikube Cypress tests" | |
config: pageLoadTimeout=100000,retries=2,video=false | |
browser: chrome | |
record: false | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
CYPRESS_user: tackle | |
CYPRESS_pass: password | |
- uses: actions/upload-artifact@v1 | |
if: failure() | |
with: | |
name: minikube-tests-screenshots | |
path: tackle-ui-tests/cypress/screenshots |