diff --git a/.github/workflows/build-migrator-cli.yml b/.github/workflows/build-migrator-cli.yml deleted file mode 100644 index 29c846c0b..000000000 --- a/.github/workflows/build-migrator-cli.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- -name: Build Migrator CLI - -on: - workflow_dispatch: - -jobs: - - stub: - name: Stub - runs-on: ubuntu-22.04 - steps: - - name: Stub - run: echo "Stub" diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index fef9c2a55..a2bba5693 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -126,6 +126,9 @@ jobs: - project_name: Scim base_path: ./bitwarden_license/src dotnet: true + - project_name: MsSqlMigratorUtility + base_path: ./util + dotnet: true steps: - name: Checkout repo uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3.3.0 @@ -246,6 +249,10 @@ jobs: base_path: ./src docker_repos: [bitwardenprod.azurecr.io, bitwardenqa.azurecr.io] dotnet: true + - project_name: MsSqlMigratorUtility + base_path: ./util + docker_repos: [bitwardenprod.azurecr.io, bitwardenqa.azurecr.io] + dotnet: true steps: - name: Checkout repo uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3.3.0 diff --git a/util/MsSqlMigratorUtility/.dockerignore b/util/MsSqlMigratorUtility/.dockerignore new file mode 100644 index 000000000..546b9afbe --- /dev/null +++ b/util/MsSqlMigratorUtility/.dockerignore @@ -0,0 +1,3 @@ +* +!obj/build-output/publish/* +!obj/Docker/empty/ diff --git a/util/MsSqlMigratorUtility/Dockerfile b/util/MsSqlMigratorUtility/Dockerfile new file mode 100644 index 000000000..314fa664e --- /dev/null +++ b/util/MsSqlMigratorUtility/Dockerfile @@ -0,0 +1,8 @@ +FROM mcr.microsoft.com/dotnet/aspnet:6.0 + +LABEL com.bitwarden.product="bitwarden" + +WORKDIR /app +COPY obj/build-output/publish . + +CMD ["sh", "-c", "dotnet /app/MsSqlMigratorUtility.dll \"${MSSQL_CONN_STRING}\" -v"]