Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update action to accomodate Kubernetes and test scenario in kubernetes #425

Open
NyakudyaA opened this issue Apr 23, 2023 · 0 comments
Open
Assignees

Comments

@NyakudyaA
Copy link
Collaborator

Feature description

All the scenario tests https://github.com/kartoza/docker-postgis/tree/develop/scenario_tests use docker-compose. This image is also being used in Kubernetes environments and it is important to test these scenarios in either minikube or Kubernetes.

Additional context

We need to update to something like

- name: Install kube-tools
      uses: superbrothers/[email protected]

    - name: Start local Kubernetes cluster or minikube
      if: runner.os == 'Linux'
      run: |
        sudo kubeadm init
        mkdir -p $HOME/.kube
        sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
        sudo chown $(id -u):$(id -g) $HOME/.kube/config
        sudo kubectl apply -f https://raw.githubusercontent.com/coreos/flannel/master/Documentation/kube-flannel.yml

    - name: Start minikube
      if: runner.os == 'Windows'
      run: |
        choco install minikube
        minikube start

    - name: Deploy kartoza/postgis image
      run: |
        kubectl create deployment postgis --image=kartoza/postgis:latest
        kubectl expose deployment postgis --port=5432 --type=LoadBalancer

    - name: Wait for deployment to be ready
      run: |
        kubectl rollout status deployment/postgis

@tharanathkartoza What is the best option in creating a deployment file to test the deployment and the scenario test. Ideally we need to convert the example https://github.com/kartoza/docker-postgis/blob/develop/scenario_tests/init_scripts/docker-compose.yml

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants