Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,22 @@ jobs:
--health-timeout 5s
--health-retries 10
rabbitmq:
# Default 'guest' user is restricted to localhost in RabbitMQ.
# GitHub Actions service containers route through port forwarding,
# so the broker sees connections as non-localhost and rejects
# 'guest'. Override with a dedicated test user.
image: rabbitmq:4-management
env:
RABBITMQ_DEFAULT_USER: trax
RABBITMQ_DEFAULT_PASS: trax123
ports:
- 5672:5672
- 15672:15672
options: >-
--health-cmd "rabbitmq-diagnostics -q ping"
--health-interval 5s
--health-timeout 5s
--health-retries 10
--health-retries 20
steps:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,11 @@ namespace Trax.Api.Tests.PersistedOperations.IntegrationTests;
[Category("Integration")]
public class RabbitMqBroadcasterTests
{
private const string AmqpUri = "amqp://guest:guest@localhost:5672/";
// Both the docker-compose dev broker (Trax.Samples/docker-compose.yml)
// and the CI service container (.github/workflows/pull_request.yml) are
// configured with these credentials. Default 'guest' would work locally
// but RabbitMQ rejects it from non-localhost in CI's port-forwarded setup.
private const string AmqpUri = "amqp://trax:trax123@localhost:5672/";

private static bool IsRabbitMqReachable()
{
Expand Down
Loading