diff --git a/.forgejo/workflows/lint-and-build.yml b/.forgejo/workflows/lint-and-build.yml index ea85199..61e15be 100644 --- a/.forgejo/workflows/lint-and-build.yml +++ b/.forgejo/workflows/lint-and-build.yml @@ -111,12 +111,8 @@ jobs: image: mongo:7 env: MONGO_INITDB_DATABASE: normogen_test - # No `ports:` mapping: the job container reaches Mongo over the job's - # internal network via the service hostname (MONGODB_URI uses `mongo`, - # not localhost). Publishing to a host port is unnecessary and collides - # with any mongod already bound to :27017 on the runner host — which - # made the service container fail to schedule ("port is already - # allocated") and aborted the whole test job before any test ran. + ports: + - 27017:27017 env: MONGODB_URI: mongodb://mongo:27017 APP_ENVIRONMENT: development