1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-28 13:00:53 -05:00

feat(self-host): [PM-14188] Add option to disable built-in MSSQL container

* Add Config Option For Disabling Built In MSSQL Container

* fix: flip bool condition and make it nullable

* fake commit to kick off an ephemeral environment

* Revert "fake commit to kick off an ephemeral environment"

This reverts commit 818f65f4d2.

* Changed the new setting to not be nullable.

---------

Co-authored-by: Justin Baur <19896123+justindbaur@users.noreply.github.com>
Co-authored-by: Todd Martin <tmartin@bitwarden.com>
This commit is contained in:
tangowithfoxtrot
2025-07-11 08:23:51 -07:00
committed by GitHub
parent 067e464ec4
commit 24b7cc417f
3 changed files with 9 additions and 0 deletions

View File

@ -97,6 +97,9 @@ public class Configuration
[Description("Enable SCIM")]
public bool EnableScim { get; set; } = false;
[Description("Enable Built-In MSSQL Container Generation")]
public bool EnableBuiltInMsSql { get; set; } = true;
[YamlIgnore]
public string Domain
{

View File

@ -42,6 +42,7 @@ public class DockerComposeBuilder
{
public TemplateModel(Context context)
{
EnableBuiltInMsSql = context.Config.EnableBuiltInMsSql;
MssqlDataDockerVolume = context.Config.DatabaseDockerVolume;
EnableKeyConnector = context.Config.EnableKeyConnector;
EnableScim = context.Config.EnableScim;
@ -61,6 +62,7 @@ public class DockerComposeBuilder
}
}
public bool EnableBuiltInMsSql { get; set; }
public bool MssqlDataDockerVolume { get; set; }
public bool EnableKeyConnector { get; set; }
public bool EnableScim { get; set; }

View File

@ -14,6 +14,7 @@
#########################################################################
services:
{{#if EnableBuiltInMsSql}}
mssql:
image: ghcr.io/bitwarden/mssql:{{{CoreVersion}}}
container_name: bitwarden-mssql
@ -32,6 +33,7 @@ services:
- ../env/uid.env
- ../env/mssql.override.env
{{/if}}
web:
image: ghcr.io/bitwarden/web:{{{WebVersion}}}
container_name: bitwarden-web
@ -106,8 +108,10 @@ services:
image: ghcr.io/bitwarden/admin:{{{CoreVersion}}}
container_name: bitwarden-admin
restart: always
{{#if EnableBuiltInMsSql}}
depends_on:
- mssql
{{/if}}
volumes:
- ../core:/etc/bitwarden/core
- ../ca-certificates:/etc/bitwarden/ca-certificates