Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add minimal, "HTTP endpoint discovery only mode" bootstrapping #723

Open
schnerring opened this issue Feb 7, 2024 · 0 comments
Open

Add minimal, "HTTP endpoint discovery only mode" bootstrapping #723

schnerring opened this issue Feb 7, 2024 · 0 comments

Comments

@schnerring
Copy link
Contributor

schnerring commented Feb 7, 2024

Is your feature request related to a problem? Please describe.

During build time, I generate the OpenAPI spec by setting <OpenApiGenerateDocumentsOnBuild>true</OpenApiGenerateDocumentsOnBuild> in the Wolverine API project, which runs dotnet-getdocument to generate the spec.

It all works fine in VS 2022, when the Postgres Docker container is up and running. But building in CI environments and the like, I get a DB connection error, because no Postgres DB exists.

Describe the solution you'd like

It would be nice to be able to bootstrap Wolverine it requiring a working DB connection.

Maybe a IServiceCollection extension similar to .DisableAllExternalWolverineTransports()?

        Host = await AlbaHost.For<Program>(builder =>
        {
            builder.ConfigureServices(services =>
            {
                // Override the Wolverine configuration to disable external DB connectivity
                services.DisableAllExternalDatabaseConnections();
            });
        });

Describe alternatives you've considered

For CI build steps it is of course possible to add a Posgres container.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant