chore(gitlab): debug services

This commit is contained in:
Michele Cereda
2024-05-02 02:04:29 +02:00
parent 19ae542d2b
commit 4bd0ff32ba
2 changed files with 37 additions and 0 deletions

View File

@@ -0,0 +1,21 @@
#!sh
# Sources:
# - https://superuser.com/questions/621870/test-if-a-port-on-a-remote-system-is-reachable-without-telnet
# TCP
nc -vz -w '3' 'localhost' '80'
nc -nvz -w '3' '127.0.0.1' '80'
timeout '3' cat < '/dev/tcp/localhost/80'
timeout '3' cat < '/dev/tcp/127.0.0.1/80'
# UDP
nc -uvz -w '3' 'localhost' '25'
nc -nuvz -w '3' '127.0.0.1' '25'
timeout '3' cat < '/dev/udp/localhost/80'
timeout '3' cat < '/dev/udp/127.0.0.1/25'

View File

@@ -0,0 +1,16 @@
---
print-postgis-service-logs:
when: manual
variables:
CI_DEBUG_SERVICES: "true"
services:
- name: "postgis/postgis:15-3.3"
alias: db
variables:
POSTGRES_DB: postgres
POSTGRES_USER: postgres
POSTGRES_PASSWORD: "postgres"
POSTGRES_HOST_AUTH_METHOD: trust
script:
- echo 'hello!!'