chore: Run integration tests on different ports (#1801)

# Summary

This PR updates the CI (integration tests) docker compose and env file so that the integration tests run on a separate set of ports, so that they can be run locally without interfering with an instance of the app running locally.

## Testing

To test locally

Start the app
```
yarn dev
```

Run the integration tests
```
make ci-int
```

Note that both can run at the same time without docker port conflicts. `make ci-int` can also be run without running the app - it uses its own independent mongo + clickhouse + api.
This commit is contained in:
Drew Davis 2026-02-25 15:52:17 -05:00 committed by GitHub
parent 247896e497
commit d760d2db5b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 15 additions and 7 deletions

View file

@ -0,0 +1,6 @@
---
"@hyperdx/api": patch
"@hyperdx/common-utils": patch
---
chore: Run integration tests on different ports

View file

@ -32,7 +32,7 @@ services:
- ./docker/clickhouse/local/users.xml:/etc/clickhouse-server/users.xml
restart: on-failure
ports:
- 8123:8123 # http api
- 18123:8123 # http api
# - 9000:9000 # native
networks:
- internal
@ -40,7 +40,7 @@ services:
image: mongo:5.0.32-focal
command: --port 29999
ports:
- 29999:29999
- 39999:29999
networks:
- internal
networks:

View file

@ -1,12 +1,13 @@
CLICKHOUSE_HOST=http://localhost:8123
# Environment configuration for Integration tests, corresponding to ports defined in docker-compose.ci.yml
CLICKHOUSE_HOST=http://localhost:18123
CLICKHOUSE_PASSWORD=api
CLICKHOUSE_USER=api
RUN_SCHEDULED_TASKS_EXTERNALLY=true
EXPRESS_SESSION_SECRET="hyperdx is cool 👋"
FRONTEND_URL=http://app:8080
MONGO_URI=mongodb://localhost:29999/hyperdx-test
MONGO_URI=mongodb://localhost:39999/hyperdx-test
NODE_ENV=test
PORT=9000
OPAMP_PORT=4320
PORT=19000 # (API port)
OPAMP_PORT=14320
# Default to only logging warnings/errors. Adjust if you need more verbosity
HYPERDX_LOG_LEVEL=warn

View file

@ -1,4 +1,5 @@
CLICKHOUSE_HOST=http://localhost:8123
# Environment configuration for Integration tests, corresponding to ports defined in docker-compose.ci.yml
CLICKHOUSE_HOST=http://localhost:18123
CLICKHOUSE_PASSWORD=
CLICKHOUSE_USER=default
NODE_ENV=test