Replies: 1 comment
-
Closing, found #9899 which is the same issue. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
In essence, I have an Aspire project like below, where the
backend
is a web server.For this server I would like like to run integration tests, so I create a test project and use the
DistributedApplicationTestingBuilder
. Runningdotnet test
on my local machine (WSL) works just like expected: the database is set up, the backend can connect to it, and a basic integration test can call the backend and get a result.Now, running locally is all good and well but then I also want to run this in my company's CI enviroment, which is Gitlab where each pipeline is run inside a container (with an image of my choosing). This is where I get issues, and the
dotnet test
fails with the following:This makes sense, as the CI environment would run the
dotnet test
inside my specified container but the SQL container is not run inside that container but next to it. As such, there is nothing onlocalhost
listening to the port.Is there a way to get this scenario working? I guess what I am looking for is a way to tell Aspire that SQL is not really running on localhost, but should kind of be regarded as an external resource. Or any sort of guidance if this is a dead end or not.
I think this might be the same question as in #6567, but that one died off.
Beta Was this translation helpful? Give feedback.
All reactions