From 5b7eae3bc069193ce3456fe89f9d345481b969a4 Mon Sep 17 00:00:00 2001 From: Pankaj Date: Mon, 12 Aug 2024 20:00:56 +0530 Subject: [PATCH] Add postgres service --- .github/workflows/test_kubernetes.yml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/.github/workflows/test_kubernetes.yml b/.github/workflows/test_kubernetes.yml index df37faae5..35ff2fbfe 100644 --- a/.github/workflows/test_kubernetes.yml +++ b/.github/workflows/test_kubernetes.yml @@ -11,6 +11,23 @@ on: jobs: run-kubernets-tests: runs-on: ubuntu-latest + services: + # Label used to access the service container + postgres: + # Docker Hub image + image: postgres + # Provide the password for postgres + env: + POSTGRES_PASSWORD: postgres + # Set health checks to wait until postgres has started + options: >- + --health-cmd pg_isready + --health-interval 10s + --health-timeout 5s + --health-retries 5 + ports: + # Maps tcp port 5432 on service container to the host + - 5432:543 steps: - uses: actions/checkout@v3 - name: Kubernetes KinD Cluster