Webwonders.Umbraco.DockerConfiguration
1.0.1
See the version list below for details.
dotnet add package Webwonders.Umbraco.DockerConfiguration --version 1.0.1
NuGet\Install-Package Webwonders.Umbraco.DockerConfiguration -Version 1.0.1
<PackageReference Include="Webwonders.Umbraco.DockerConfiguration" Version="1.0.1" />
paket add Webwonders.Umbraco.DockerConfiguration --version 1.0.1
#r "nuget: Webwonders.Umbraco.DockerConfiguration, 1.0.1"
// Install Webwonders.Umbraco.DockerConfiguration as a Cake Addin #addin nuget:?package=Webwonders.Umbraco.DockerConfiguration&version=1.0.1 // Install Webwonders.Umbraco.DockerConfiguration as a Cake Tool #tool nuget:?package=Webwonders.Umbraco.DockerConfiguration&version=1.0.1
Webwonders.Umbraco.DockerConfiguration
Webwonders.Umbraco.DockerConfiguration
is a lightweight NuGet package to simplify Docker-based SQL Server configuration for Umbraco 13+ projects. It automates Docker setup, connection string generation, and ensures compatibility with Umbraco.
Features
- Detects and validates Docker installation and status.
- Generates and starts a Docker Compose file for SQL Server.
- Automatically configures the Umbraco connection string.
- Supports seamless integration with
launchSettings.json
.
Installation
To install the package, run:
Install-Package Webwonders.Umbraco.DockerConfiguration
Or, using the .NET CLI:
dotnet add package Webwonders.Umbraco.DockerConfiguration
Usage
Add the middleware to your IConfigurationBuilder
in Program.cs
:
using Webwonders.Umbraco.DockerConfiguration;
var builder = WebApplication.CreateBuilder(args);
// Enable Docker-based SQL Server configuration
DockerConfigurationMiddleware.ConfigureDockerSqlDb(builder.Configuration);
// Continue building the app...
Prerequisites
- Ensure Docker Desktop is installed and running.
- Add the following environment variables to
launchSettings.json
under theUmbracoProject
profile:
"environmentVariables": {
"Use_Local_Docker_SQL": "true",
"Local_Docker_DB_NAME": "MyDatabase",
"Local_Docker_PASSWORD": "YourStrongPassword123",
"Local_Docker_PORT": "1433"
}
How It Works
- Docker Validation: Checks if Docker is installed and running.
- Docker Compose Generation: Creates a
docker-compose.yml
file for SQL Server. - Connection String Configuration: Adds the SQL Server connection string dynamically to the Umbraco configuration.
Contributing
Contributions are welcome! Please submit a pull request or open an issue on GitHub.
License
This project is licensed under the MIT License. See the LICENSE file for details.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. |
-
net8.0
- Microsoft.Extensions.Configuration (>= 9.0.1)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.