feat: adding hostmetrics receiver for otel and jeager tracing and metrics added for spdk using go otel sdk #473
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Docker | |
on: | |
workflow_dispatch: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
env: | |
REGISTRY: ghcr.io | |
IMAGE_NAME: ${{ github.repository }} | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Build & Start containers | |
run: docker compose up --build --force-recreate --detach | |
- name: Run tests | |
run: | | |
set -x | |
echo wait 5s for SPDK to start... && sleep 5s | |
docker compose logs | |
docker compose ps | |
docker inspect --format='{{json .Name}} - {{json .State.Health.Status}}' $(docker compose ps -q) | |
uniq -c <<< $(docker inspect --format='{{json .State.Health.Status}}' $(docker compose ps -q)) | grep -q '4 "healthy"' || true | |
docker compose exec -T spdk /usr/local/bin/spdk_nvme_perf -r 'traddr:127.0.0.1 trtype:TCP adrfam:IPv4 trsvcid:4420' -c 0x1 -q 1 -o 4096 -w randread -t 10 || true | |
echo wait 15s for prometheus to start... && sleep 15s | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=mem_free | grep mem_free | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=cpu_usage_user | grep cpu_usage_user | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=dpu_bytes_read | grep dpu_bytes_read | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=net_bytes_recv_total | grep net_bytes_recv_total | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=nginx_requests | grep nginx_requests | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=redfish_thermal_fans_reading_rpm | grep redfish_thermal_fans_reading_rpm | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=disk_used_percent | grep disk_used_percent | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=netstat_tcp_listen | grep netstat_tcp_listen | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=dns_query_result_code | grep dns_query_result_code | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=ethtool_duplex | grep ethtool_duplex | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=kernel_boot_time_total | grep kernel_boot_time_total | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=system_cpu_time_seconds_total | grep system_cpu_time_seconds_total | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=system_disk_io_time_seconds_total | grep system_disk_io_time_seconds_total | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=system_filesystem_inodes_usage | grep system_filesystem_inodes_usage | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=system_memory_usage_bytes | grep system_memory_usage_bytes | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=system_network_connections | grep system_network_connections | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=system_paging_faults_total | grep system_paging_faults_total | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=system_processes_count | grep system_processes_count | |
echo "Wait 3 minutes for go app to start..." && sleep 3m | |
curl --fail http://127.0.0.1:9091/api/v1/query?query=spdk_bdev_bytes_read_total | grep spdk_bdev_bytes_read_total | |
curl "http://127.0.0.1:16686/api/traces?service=spdk-client&limit=1" | |
- name: Logs | |
if: always() | |
run: docker compose logs | |
- name: Stop containers | |
if: always() | |
run: docker compose down --volumes --remove-orphans |