Skip to content

Update local with changes to on-prem #10

Update local with changes to on-prem

Update local with changes to on-prem #10

Workflow file for this run

# This workflow will test that the local k8s setup does not error
# This is useful to keep an eye on version incompatibilities
name: Local test
on:
push:
branches: [ main ]
pull_request:
workflow_dispatch:
jobs:
test:
name: Start up local kubernetes pods
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v2
- name: start minikube
id: minikube
uses: medyagh/setup-minikube@latest
with:
cache: false
start-args: '--static-ip 192.168.49.2'
- name: test cluster
run: |
minikube ip
kubectl get pods -A
- name: build image
run: |
export SHELL=/bin/bash
eval $(minikube -p minikube docker-env)
docker build local_k8s/containers/omero-server -t omero-server
docker build local_k8s/containers/omero-web -t omero-web
echo -n "verifying images:"
docker images
- name: startup pods
run: kubectl apply -k local_k8s/test
- name: sleep for 5 min
run: sleep 300s
- name: print pods
run: kubectl get pods -A
- name: server logs
run: kubectl logs omero-server
- name: omero logs
run: |
kubectl exec omero-server -- bash -c "tail /opt/omero/server/OMERO.server/var/log/Blitz-0.log"
echo $(kubectl exec omero-server -- bash -c "cat /opt/omero/server/OMERO.server/var/log/Blitz-0.log" | grep ERROR)
kubectl exec omero-server -- bash -c "tail /opt/omero/server/OMERO.server/var/log/master.err"
- name: test servers
run: |
kubectl exec omero-server -- bash -c "/opt/omero/server/server_venv/bin/omero login -u root -w omero -s 127.0.0.1:4064"
- name: test web
run: |
kubectl port-forward svc/omero-web 8080:80 --address='0.0.0.0' &
sleep 30s
echo "localhost:8080"
curl -I localhost:8080
echo "192.168.49.2:80"
curl -I 192.168.49.2