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

build: error annotation for postman CI #4153

Closed
wants to merge 5 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 12 additions & 10 deletions .github/workflows/postman_e2e_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,6 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v3

- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '21'

- name: Change DNS
run: |
sudo sed -i 's/#DNS=/DNS=ns2.fra.cloud.inovex.io/' /etc/systemd/resolved.conf
Expand All @@ -29,16 +24,14 @@ jobs:
sudo systemctl restart systemd-resolved
dig +short github.com

- name: Install Newman
run: npm install -g newman

- name: Wait for cluster to become healthy
id: wait-for-cluster
env:
BASE_URL: ${{ inputs.base_url }}
run: |
retries=0
until [ $retries -ge 3 ]
max_retries=3
until [ $retries -ge $max_retries ]
do
response=$(curl -s -k -o /dev/null -w "%{http_code}" "$BASE_URL/api/health")
if [ "$response" = "204" ]; then
Expand All @@ -52,9 +45,18 @@ jobs:
done
if [ "$response" != "204" ]; then
echo "Cluster is still not responding after retries. Exiting..."
echo "::error ::Cluster is not responding after $max_retries attempts. Status: $response"
exit 1
fi


- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '21'

- name: Install Newman
run: npm install -g newman

- name: Run Newman script
working-directory: ./server
run: |
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ yarn-error.log*
build
server/src/main
server/src/server
server/src/tmp

# misc
.DS_Store
Expand Down
Loading