send updates every 5 secs #10
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: Test | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
jobs: | |
install-playwright: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: pnpm/action-setup@v4 | |
with: | |
version: 9 | |
- name: Set up Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: "22" | |
- name: Run Netdata | |
run: | | |
echo '[prometheus_remote_write:prom] | |
enabled = yes | |
destination = ${{ secrets.PROMETHEUS_REMOTE_WRITE_DESTINATION }} | |
username = ${{ secrets.PROMETHEUS_REMOTE_WRITE_USERNAME }} | |
password = ${{ secrets.PROMETHEUS_REMOTE_WRITE_PASSWORD }} | |
remote write URL path = /api/v1/write | |
update every = 5 | |
' > exporting.conf | |
docker run -d --rm \ | |
--name netdata \ | |
--hostname gha${{ github.repository_id }}-${{ github.run_id }}-${{ github.run_attempt }} \ | |
--pid host \ | |
--network host \ | |
--cap-add SYS_PTRACE \ | |
--cap-add SYS_ADMIN \ | |
--security-opt apparmor=unconfined \ | |
-v /:/host/root:ro,rslave \ | |
-v /etc/passwd:/host/etc/passwd:ro \ | |
-v /etc/group:/host/etc/group:ro \ | |
-v /etc/localtime:/etc/localtime:ro \ | |
-v /proc:/host/proc:ro \ | |
-v /sys:/host/sys:ro \ | |
-v /etc/os-release:/host/etc/os-release:ro \ | |
-v /var/log:/host/var/log:ro \ | |
-v /var/run/docker.sock:/var/run/docker.sock:ro \ | |
-v /run/dbus:/run/dbus:ro \ | |
-v $PWD/exporting.conf:/etc/netdata/exporting.conf:ro \ | |
netdata/netdata | |
- name: Install Playwright and dependencies | |
run: pnpx playwright install --with-deps | |
- name: Print netdata logs | |
run: docker logs netdata |