From f1eb41f944bbc01521e90cdc90564f592c6e2c21 Mon Sep 17 00:00:00 2001 From: binon Date: Wed, 10 Jan 2024 14:15:08 +0000 Subject: [PATCH 01/19] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 2ed35e5ab..d7454219f 100644 --- a/README.md +++ b/README.md @@ -94,7 +94,7 @@ Create a Local IIS launch profile for the following projects: - LearningHub.Nhs.WebUI = https://lh-web.dev.local 7. Tick the checkbox for **Enable Anonymous Authentication**. -## Rebuild and run +## Rebuild and run 1. Rebuild the solution 2. Set **LearningHub.Nhs.WebUI** as the startup Project From 1f9521c1fcb9b3baf26590b880e169044af62efc Mon Sep 17 00:00:00 2001 From: binon Date: Wed, 10 Jan 2024 22:13:16 +0000 Subject: [PATCH 02/19] Addding key --- .gitignore | 4 ++++ LearningHub.Nhs.WebUI/Program.cs | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index e0af672bf..0afa44753 100644 --- a/.gitignore +++ b/.gitignore @@ -43,3 +43,7 @@ obj /AdminUI/LearningHub.Nhs.AdminUI/Properties/launchSettings.json /WebAPI/LearningHub.Nhs.API/Properties/launchSettings.json /WebAPI/LearningHub.Nhs.API/appsettings.Development.json +/WebAPI/LearningHub.Nhs.Database/LearningHub.Nhs.Database.dbmdl +/WebAPI/LearningHub.Nhs.Database/LearningHub.Nhs.Database.jfm +/WebAPI/MigrationTool/LearningHub.Nhs.Migration.Staging.Database/LearningHub.Nhs.Migration.Staging.Database.dbmdl +/WebAPI/MigrationTool/LearningHub.Nhs.Migration.Staging.Database/LearningHub.Nhs.Migration.Staging.Database.jfm diff --git a/LearningHub.Nhs.WebUI/Program.cs b/LearningHub.Nhs.WebUI/Program.cs index 2352d0bc3..ec9685f50 100644 --- a/LearningHub.Nhs.WebUI/Program.cs +++ b/LearningHub.Nhs.WebUI/Program.cs @@ -33,7 +33,7 @@ var builder = WebApplication.CreateBuilder(args); - builder.Configuration.AddUserSecrets(string.Empty); + builder.Configuration.AddUserSecrets("a2ecb5d2-cf13-4551-9cb6-3d86dfbcf8ef"); builder.Logging.ClearProviders(); builder.Logging.SetMinimumLevel(Microsoft.Extensions.Logging.LogLevel.Trace); From aed3dec61c1220c83da98a38af956c382aa2e447 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 16:22:40 +0000 Subject: [PATCH 03/19] Triggering CI in Azure Pipeline --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index d7454219f..7ca2fa3c5 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# Introduction +# Introduction This is the official open-source repository for the [Learning Hub](https://learninghub.nhs.uk/) platform. The Learning Hub is the national digital learning platform providing easy access to a wide range of educational resources and support for the health and care workforce and educators. From 9851951fe16528f242d4195e1c04137f2d7a875c Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 16:42:22 +0000 Subject: [PATCH 04/19] Test trigger 2 CI --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 7ca2fa3c5..e30e445d2 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ The Learning Hub is provided and supported by the Technology Enhanced Learning P # Getting Started -## Required installs +## Required installs - [Visual Studio Professional 2022](https://visualstudio.microsoft.com/downloads/) or other suitable An IDE that supports the Microsoft Tech Stack - Make sure you have the [NPM Task Runner](https://marketplace.visualstudio.com/items?itemName=MadsKristensen.NPMTaskRunner) extension - SQL Server 2019 From 3699ef32669514a0d6c0b6f2ee1d80e7db2ae05b Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 16:50:03 +0000 Subject: [PATCH 05/19] Create azure-pipelines-webui-ci.yml --- azure-pipelines-webui-ci.yml | 110 +++++++++++++++++++++++++++++++++++ 1 file changed, 110 insertions(+) create mode 100644 azure-pipelines-webui-ci.yml diff --git a/azure-pipelines-webui-ci.yml b/azure-pipelines-webui-ci.yml new file mode 100644 index 000000000..220ced972 --- /dev/null +++ b/azure-pipelines-webui-ci.yml @@ -0,0 +1,110 @@ +# Variable Group 'UAT - Variable Group' was defined in the Variables tab +variables: +- name: BuildParameters.RestoreBuildProjects + value: '**/*.csproj' +- name: BuildParameters.TestProjects + value: '**/*[Tt]ests/*.csproj' +name: $(date:yyyyMMdd)$(rev:.r) +resources: + repositories: + - repository: self + type: git + ref: refs/heads/CI +jobs: +- job: Job_1 + displayName: Agent job + pool: + vmImage: windows-latest + steps: + - checkout: self + clean: true + fetchTags: true + - task: NodeTool@0 + displayName: Use Node 12.19 (otherwise node-sass 4.13 will error - Azure build agent defaults to v14.15 which is incompatible) + inputs: + versionSpec: 12.19 + - task: Npm@1 + displayName: npm custom + inputs: + command: custom + workingDir: LearningHub.Nhs.WebUI + verbose: false + customCommand: install -f + - task: Npm@1 + displayName: run webpack build + inputs: + command: custom + workingDir: LearningHub.Nhs.WebUI + verbose: false + customCommand: run build + - task: NuGetToolInstaller@1 + displayName: Use NuGet 5.8 + inputs: + versionSpec: 5.8 + - task: NuGetCommand@2 + displayName: NuGet restore + inputs: + feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 + - task: DotNetCoreCLI@2 + displayName: Restore + inputs: + command: restore + projects: $(BuildParameters.RestoreBuildProjects) + - task: DotNetCoreCLI@2 + displayName: Build + inputs: + projects: $(BuildParameters.RestoreBuildProjects) + arguments: --configuration $(BuildConfiguration) + - task: DotNetCoreCLI@2 + displayName: Test + enabled: False + inputs: + command: test + projects: $(BuildParameters.TestProjects) + arguments: --configuration $(BuildConfiguration) + - task: DotNetCoreCLI@2 + displayName: Publish WebUI + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.Nhs.WebUI.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/WebUI + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: Publish Artifact WebUI + condition: succeededOrFailed() + inputs: + PathtoPublish: $(Build.ArtifactStagingDirectory)/WebUI + ArtifactName: WebUI + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' + - task: DotNetCoreCLI@2 + displayName: Publish AdminUI + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.Nhs.AdminUI.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/AdminUI + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: Publish Artifact AdminUI + condition: succeededOrFailed() + inputs: + PathtoPublish: $(Build.ArtifactStagingDirectory)/AdminUI + ArtifactName: AdminUI + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' + - task: DotNetCoreCLI@2 + displayName: Publish WebAPI + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.Nhs.Api.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/WebAPI + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: 'Publish Artifact WebAPI ' + condition: succeededOrFailed() + inputs: + PathtoPublish: $(Build.ArtifactStagingDirectory)/WebAPI + ArtifactName: WebAPI + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' +... From 692df2b99928d646ab03a9c1646ea27596683ca9 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 17:10:24 +0000 Subject: [PATCH 06/19] Update azure-pipelines-webui-ci.yml for Azure Pipelines --- azure-pipelines-webui-ci.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/azure-pipelines-webui-ci.yml b/azure-pipelines-webui-ci.yml index 220ced972..6e6b1701e 100644 --- a/azure-pipelines-webui-ci.yml +++ b/azure-pipelines-webui-ci.yml @@ -4,6 +4,10 @@ variables: value: '**/*.csproj' - name: BuildParameters.TestProjects value: '**/*[Tt]ests/*.csproj' +trigger: + branches: + include: + - refs/heads/ci name: $(date:yyyyMMdd)$(rev:.r) resources: repositories: From ae4a205d6beb1a1e20831fa16c0e38ae9dc8aa45 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 17:11:41 +0000 Subject: [PATCH 07/19] Update CI to test trigger --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e30e445d2..9e666ee7b 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# Introduction +# Introduction This is the official open-source repository for the [Learning Hub](https://learninghub.nhs.uk/) platform. The Learning Hub is the national digital learning platform providing easy access to a wide range of educational resources and support for the health and care workforce and educators. From 81c2533ade93609635a4e0e7a6a7992a378bf1f6 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 17:15:36 +0000 Subject: [PATCH 08/19] Update azure-pipelines-webui-ci.yml for Azure Pipelines --- azure-pipelines-webui-ci.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/azure-pipelines-webui-ci.yml b/azure-pipelines-webui-ci.yml index 6e6b1701e..509faf6a5 100644 --- a/azure-pipelines-webui-ci.yml +++ b/azure-pipelines-webui-ci.yml @@ -5,9 +5,7 @@ variables: - name: BuildParameters.TestProjects value: '**/*[Tt]ests/*.csproj' trigger: - branches: - include: - - refs/heads/ci + - CI name: $(date:yyyyMMdd)$(rev:.r) resources: repositories: From bbd15a6b0192bb1e7275877603e900b687b9eeea Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 17:16:34 +0000 Subject: [PATCH 09/19] trigger commit ci --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 9e666ee7b..e30e445d2 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# Introduction +# Introduction This is the official open-source repository for the [Learning Hub](https://learninghub.nhs.uk/) platform. The Learning Hub is the national digital learning platform providing easy access to a wide range of educational resources and support for the health and care workforce and educators. From 279b7cab1b4aba92cac8d27ff9b1f06dd8e0ba4b Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 22:24:27 +0000 Subject: [PATCH 10/19] Create LearningHub OpenAPI-ReportAPI-CI.yml --- .../LearningHub OpenAPI-ReportAPI-CI.yml | 85 +++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 .github/workflows/LearningHub OpenAPI-ReportAPI-CI.yml diff --git a/.github/workflows/LearningHub OpenAPI-ReportAPI-CI.yml b/.github/workflows/LearningHub OpenAPI-ReportAPI-CI.yml new file mode 100644 index 000000000..0446b79c2 --- /dev/null +++ b/.github/workflows/LearningHub OpenAPI-ReportAPI-CI.yml @@ -0,0 +1,85 @@ +# Agent Queue 'Azure Pipelines' was used with unrecognized Agent Specification, vmImage property must be specified to determine image - https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#software +variables: +- name: BuildParameters.RestoreBuildProjects + value: '**/*.csproj' +- name: BuildParameters.projects + value: '**/*.csproj' +trigger: + - CI +name: $(date:yyyyMMdd)$(rev:.r) +resources: + repositories: + - repository: self + type: git + ref: refs/heads/RC +jobs: +- job: Job_1 + displayName: Agent job + pool: + vmImage: windows-latest + steps: + - checkout: self + clean: true + fetchTags: false + - task: NuGetToolInstaller@1 + displayName: Use NuGet 5.8 + inputs: + versionSpec: 5.8 + - task: NuGetCommand@2 + displayName: NuGet restore + inputs: + feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 + - task: DotNetCoreCLI@2 + displayName: Restore + inputs: + command: restore + projects: $(BuildParameters.RestoreBuildProjects) + feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 + - task: DotNetCoreCLI@2 + displayName: Build + inputs: + projects: $(BuildParameters.projects) + arguments: --configuration $(BuildConfiguration) /p:Platform=x64 + - task: DotNetCoreCLI@2 + displayName: Test OpenAPI + inputs: + command: test + projects: '**/*LearningHub.Nhs.OpenApi.Tests.csproj' + arguments: --configuration Debug + - task: DotNetCoreCLI@2 + displayName: Test ReportAPI + inputs: + command: test + projects: '**/*LearningHub.Nhs.ReportApi.Services.UnitTests.csproj' + arguments: --configuration Debug + - task: DotNetCoreCLI@2 + displayName: Publish OpenAPI + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.NHS.OpenAPI.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/OpenAPI + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: Publish Artifact OpenAPI + condition: succeededOrFailed() + inputs: + PathtoPublish: $(build.artifactstagingdirectory)/OpenAPI + ArtifactName: OpenAPI + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' + - task: DotNetCoreCLI@2 + displayName: Publish ReportAPI + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.Nhs.ReportApi.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/ReportAPI + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: Publish Artifact ReportAPI + condition: succeededOrFailed() + inputs: + PathtoPublish: $(build.artifactstagingdirectory)/ReportAPI + ArtifactName: ReportAPI + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' +... From 26e01994b57570c440398dab8967dcfc390b073c Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 22:46:12 +0000 Subject: [PATCH 11/19] Delete .github/workflows/LearningHub OpenAPI-ReportAPI-CI.yml --- .../LearningHub OpenAPI-ReportAPI-CI.yml | 85 ------------------- 1 file changed, 85 deletions(-) delete mode 100644 .github/workflows/LearningHub OpenAPI-ReportAPI-CI.yml diff --git a/.github/workflows/LearningHub OpenAPI-ReportAPI-CI.yml b/.github/workflows/LearningHub OpenAPI-ReportAPI-CI.yml deleted file mode 100644 index 0446b79c2..000000000 --- a/.github/workflows/LearningHub OpenAPI-ReportAPI-CI.yml +++ /dev/null @@ -1,85 +0,0 @@ -# Agent Queue 'Azure Pipelines' was used with unrecognized Agent Specification, vmImage property must be specified to determine image - https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#software -variables: -- name: BuildParameters.RestoreBuildProjects - value: '**/*.csproj' -- name: BuildParameters.projects - value: '**/*.csproj' -trigger: - - CI -name: $(date:yyyyMMdd)$(rev:.r) -resources: - repositories: - - repository: self - type: git - ref: refs/heads/RC -jobs: -- job: Job_1 - displayName: Agent job - pool: - vmImage: windows-latest - steps: - - checkout: self - clean: true - fetchTags: false - - task: NuGetToolInstaller@1 - displayName: Use NuGet 5.8 - inputs: - versionSpec: 5.8 - - task: NuGetCommand@2 - displayName: NuGet restore - inputs: - feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 - - task: DotNetCoreCLI@2 - displayName: Restore - inputs: - command: restore - projects: $(BuildParameters.RestoreBuildProjects) - feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 - - task: DotNetCoreCLI@2 - displayName: Build - inputs: - projects: $(BuildParameters.projects) - arguments: --configuration $(BuildConfiguration) /p:Platform=x64 - - task: DotNetCoreCLI@2 - displayName: Test OpenAPI - inputs: - command: test - projects: '**/*LearningHub.Nhs.OpenApi.Tests.csproj' - arguments: --configuration Debug - - task: DotNetCoreCLI@2 - displayName: Test ReportAPI - inputs: - command: test - projects: '**/*LearningHub.Nhs.ReportApi.Services.UnitTests.csproj' - arguments: --configuration Debug - - task: DotNetCoreCLI@2 - displayName: Publish OpenAPI - inputs: - command: publish - publishWebProjects: false - projects: '**/*LearningHub.NHS.OpenAPI.csproj' - arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/OpenAPI - zipAfterPublish: True - - task: PublishBuildArtifacts@1 - displayName: Publish Artifact OpenAPI - condition: succeededOrFailed() - inputs: - PathtoPublish: $(build.artifactstagingdirectory)/OpenAPI - ArtifactName: OpenAPI - TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' - - task: DotNetCoreCLI@2 - displayName: Publish ReportAPI - inputs: - command: publish - publishWebProjects: false - projects: '**/*LearningHub.Nhs.ReportApi.csproj' - arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/ReportAPI - zipAfterPublish: True - - task: PublishBuildArtifacts@1 - displayName: Publish Artifact ReportAPI - condition: succeededOrFailed() - inputs: - PathtoPublish: $(build.artifactstagingdirectory)/ReportAPI - ArtifactName: ReportAPI - TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' -... From ad9beb92be2a575be638ca2e68d2ac187bf3cd45 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 22:46:31 +0000 Subject: [PATCH 12/19] Create LearningHub OpenAPI-ReportAPI-CI.yml --- .github/LearningHub OpenAPI-ReportAPI-CI.yml | 85 ++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 .github/LearningHub OpenAPI-ReportAPI-CI.yml diff --git a/.github/LearningHub OpenAPI-ReportAPI-CI.yml b/.github/LearningHub OpenAPI-ReportAPI-CI.yml new file mode 100644 index 000000000..0446b79c2 --- /dev/null +++ b/.github/LearningHub OpenAPI-ReportAPI-CI.yml @@ -0,0 +1,85 @@ +# Agent Queue 'Azure Pipelines' was used with unrecognized Agent Specification, vmImage property must be specified to determine image - https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#software +variables: +- name: BuildParameters.RestoreBuildProjects + value: '**/*.csproj' +- name: BuildParameters.projects + value: '**/*.csproj' +trigger: + - CI +name: $(date:yyyyMMdd)$(rev:.r) +resources: + repositories: + - repository: self + type: git + ref: refs/heads/RC +jobs: +- job: Job_1 + displayName: Agent job + pool: + vmImage: windows-latest + steps: + - checkout: self + clean: true + fetchTags: false + - task: NuGetToolInstaller@1 + displayName: Use NuGet 5.8 + inputs: + versionSpec: 5.8 + - task: NuGetCommand@2 + displayName: NuGet restore + inputs: + feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 + - task: DotNetCoreCLI@2 + displayName: Restore + inputs: + command: restore + projects: $(BuildParameters.RestoreBuildProjects) + feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 + - task: DotNetCoreCLI@2 + displayName: Build + inputs: + projects: $(BuildParameters.projects) + arguments: --configuration $(BuildConfiguration) /p:Platform=x64 + - task: DotNetCoreCLI@2 + displayName: Test OpenAPI + inputs: + command: test + projects: '**/*LearningHub.Nhs.OpenApi.Tests.csproj' + arguments: --configuration Debug + - task: DotNetCoreCLI@2 + displayName: Test ReportAPI + inputs: + command: test + projects: '**/*LearningHub.Nhs.ReportApi.Services.UnitTests.csproj' + arguments: --configuration Debug + - task: DotNetCoreCLI@2 + displayName: Publish OpenAPI + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.NHS.OpenAPI.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/OpenAPI + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: Publish Artifact OpenAPI + condition: succeededOrFailed() + inputs: + PathtoPublish: $(build.artifactstagingdirectory)/OpenAPI + ArtifactName: OpenAPI + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' + - task: DotNetCoreCLI@2 + displayName: Publish ReportAPI + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.Nhs.ReportApi.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/ReportAPI + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: Publish Artifact ReportAPI + condition: succeededOrFailed() + inputs: + PathtoPublish: $(build.artifactstagingdirectory)/ReportAPI + ArtifactName: ReportAPI + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' +... From 2f656ef416561d193a3d4efe974d74a5902e5851 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 22:52:06 +0000 Subject: [PATCH 13/19] Update CI README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e30e445d2..9e666ee7b 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# Introduction +# Introduction This is the official open-source repository for the [Learning Hub](https://learninghub.nhs.uk/) platform. The Learning Hub is the national digital learning platform providing easy access to a wide range of educational resources and support for the health and care workforce and educators. From 4a4d65df49115287d034c923c2c41b6eca7aa4f1 Mon Sep 17 00:00:00 2001 From: binon Date: Wed, 17 Jan 2024 10:43:31 +0000 Subject: [PATCH 14/19] Create LearningHub Database-CI.yml --- .github/LearningHub Database-CI.yml | 30 +++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 .github/LearningHub Database-CI.yml diff --git a/.github/LearningHub Database-CI.yml b/.github/LearningHub Database-CI.yml new file mode 100644 index 000000000..8415569c7 --- /dev/null +++ b/.github/LearningHub Database-CI.yml @@ -0,0 +1,30 @@ +trigger: + - CI +resources: + repositories: + - repository: self + type: git + ref: refs/heads/CI +jobs: +- job: Job_1 + displayName: Agent job + pool: + vmImage: windows-2019 + steps: + - checkout: self + clean: true + fetchTags: false + - task: MSBuild@1 + displayName: Build solution **/LearningHub.Nhs.Database.sqlproj + inputs: + solution: '**/LearningHub.Nhs.Database.sqlproj' + msbuildArchitecture: x64 + - task: CopyFiles@2 + displayName: Copy SQL Dacpac File + inputs: + SourceFolder: $(agent.builddirectory)\s + Contents: '**\LearningHub.Nhs.Database.dacpac' + TargetFolder: $(build.artifactstagingdirectory) + - task: PublishBuildArtifacts@1 + displayName: 'Publish Artifact: drop' +... From 914ed158e790d25aa7761e4c3a016df6178d6e84 Mon Sep 17 00:00:00 2001 From: binon Date: Wed, 17 Jan 2024 11:10:56 +0000 Subject: [PATCH 15/19] Create azure-pipeline-webui-ci.yml --- .github/azure-pipeline-webui-ci.yml | 112 ++++++++++++++++++++++++++++ 1 file changed, 112 insertions(+) create mode 100644 .github/azure-pipeline-webui-ci.yml diff --git a/.github/azure-pipeline-webui-ci.yml b/.github/azure-pipeline-webui-ci.yml new file mode 100644 index 000000000..509faf6a5 --- /dev/null +++ b/.github/azure-pipeline-webui-ci.yml @@ -0,0 +1,112 @@ +# Variable Group 'UAT - Variable Group' was defined in the Variables tab +variables: +- name: BuildParameters.RestoreBuildProjects + value: '**/*.csproj' +- name: BuildParameters.TestProjects + value: '**/*[Tt]ests/*.csproj' +trigger: + - CI +name: $(date:yyyyMMdd)$(rev:.r) +resources: + repositories: + - repository: self + type: git + ref: refs/heads/CI +jobs: +- job: Job_1 + displayName: Agent job + pool: + vmImage: windows-latest + steps: + - checkout: self + clean: true + fetchTags: true + - task: NodeTool@0 + displayName: Use Node 12.19 (otherwise node-sass 4.13 will error - Azure build agent defaults to v14.15 which is incompatible) + inputs: + versionSpec: 12.19 + - task: Npm@1 + displayName: npm custom + inputs: + command: custom + workingDir: LearningHub.Nhs.WebUI + verbose: false + customCommand: install -f + - task: Npm@1 + displayName: run webpack build + inputs: + command: custom + workingDir: LearningHub.Nhs.WebUI + verbose: false + customCommand: run build + - task: NuGetToolInstaller@1 + displayName: Use NuGet 5.8 + inputs: + versionSpec: 5.8 + - task: NuGetCommand@2 + displayName: NuGet restore + inputs: + feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 + - task: DotNetCoreCLI@2 + displayName: Restore + inputs: + command: restore + projects: $(BuildParameters.RestoreBuildProjects) + - task: DotNetCoreCLI@2 + displayName: Build + inputs: + projects: $(BuildParameters.RestoreBuildProjects) + arguments: --configuration $(BuildConfiguration) + - task: DotNetCoreCLI@2 + displayName: Test + enabled: False + inputs: + command: test + projects: $(BuildParameters.TestProjects) + arguments: --configuration $(BuildConfiguration) + - task: DotNetCoreCLI@2 + displayName: Publish WebUI + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.Nhs.WebUI.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/WebUI + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: Publish Artifact WebUI + condition: succeededOrFailed() + inputs: + PathtoPublish: $(Build.ArtifactStagingDirectory)/WebUI + ArtifactName: WebUI + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' + - task: DotNetCoreCLI@2 + displayName: Publish AdminUI + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.Nhs.AdminUI.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/AdminUI + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: Publish Artifact AdminUI + condition: succeededOrFailed() + inputs: + PathtoPublish: $(Build.ArtifactStagingDirectory)/AdminUI + ArtifactName: AdminUI + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' + - task: DotNetCoreCLI@2 + displayName: Publish WebAPI + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.Nhs.Api.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/WebAPI + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: 'Publish Artifact WebAPI ' + condition: succeededOrFailed() + inputs: + PathtoPublish: $(Build.ArtifactStagingDirectory)/WebAPI + ArtifactName: WebAPI + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' +... From 07081ceacd4a14fdc28ff0f0041a14b70bcd670c Mon Sep 17 00:00:00 2001 From: binon Date: Wed, 17 Jan 2024 11:11:44 +0000 Subject: [PATCH 16/19] Rename LearningHub OpenAPI-ReportAPI-CI.yml to azure-pipeline-openApi-reportApi-CI.yml --- ...I-ReportAPI-CI.yml => azure-pipeline-openApi-reportApi-CI.yml} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/{LearningHub OpenAPI-ReportAPI-CI.yml => azure-pipeline-openApi-reportApi-CI.yml} (100%) diff --git a/.github/LearningHub OpenAPI-ReportAPI-CI.yml b/.github/azure-pipeline-openApi-reportApi-CI.yml similarity index 100% rename from .github/LearningHub OpenAPI-ReportAPI-CI.yml rename to .github/azure-pipeline-openApi-reportApi-CI.yml From 6a550912143c3042c8427a4b1a5df80f3eb688e2 Mon Sep 17 00:00:00 2001 From: binon Date: Wed, 17 Jan 2024 11:12:09 +0000 Subject: [PATCH 17/19] Rename LearningHub Database-CI.yml to azure-pipeline-database-ci.yml --- ...LearningHub Database-CI.yml => azure-pipeline-database-ci.yml} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/{LearningHub Database-CI.yml => azure-pipeline-database-ci.yml} (100%) diff --git a/.github/LearningHub Database-CI.yml b/.github/azure-pipeline-database-ci.yml similarity index 100% rename from .github/LearningHub Database-CI.yml rename to .github/azure-pipeline-database-ci.yml From c4bb351a9b43874e2a6aa7c3adc454ee7f43cf93 Mon Sep 17 00:00:00 2001 From: binon Date: Wed, 17 Jan 2024 11:12:34 +0000 Subject: [PATCH 18/19] Rename azure-pipeline-openApi-reportApi-CI.yml to azure-pipeline-openapi-reportapi-ci.yml --- ...i-reportApi-CI.yml => azure-pipeline-openapi-reportapi-ci.yml} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/{azure-pipeline-openApi-reportApi-CI.yml => azure-pipeline-openapi-reportapi-ci.yml} (100%) diff --git a/.github/azure-pipeline-openApi-reportApi-CI.yml b/.github/azure-pipeline-openapi-reportapi-ci.yml similarity index 100% rename from .github/azure-pipeline-openApi-reportApi-CI.yml rename to .github/azure-pipeline-openapi-reportapi-ci.yml From 59d465e71b3be9f428c08f0b8f51f062fc1dc476 Mon Sep 17 00:00:00 2001 From: binon Date: Wed, 17 Jan 2024 11:13:13 +0000 Subject: [PATCH 19/19] Delete azure-pipelines-webui-ci.yml --- azure-pipelines-webui-ci.yml | 112 ----------------------------------- 1 file changed, 112 deletions(-) delete mode 100644 azure-pipelines-webui-ci.yml diff --git a/azure-pipelines-webui-ci.yml b/azure-pipelines-webui-ci.yml deleted file mode 100644 index 509faf6a5..000000000 --- a/azure-pipelines-webui-ci.yml +++ /dev/null @@ -1,112 +0,0 @@ -# Variable Group 'UAT - Variable Group' was defined in the Variables tab -variables: -- name: BuildParameters.RestoreBuildProjects - value: '**/*.csproj' -- name: BuildParameters.TestProjects - value: '**/*[Tt]ests/*.csproj' -trigger: - - CI -name: $(date:yyyyMMdd)$(rev:.r) -resources: - repositories: - - repository: self - type: git - ref: refs/heads/CI -jobs: -- job: Job_1 - displayName: Agent job - pool: - vmImage: windows-latest - steps: - - checkout: self - clean: true - fetchTags: true - - task: NodeTool@0 - displayName: Use Node 12.19 (otherwise node-sass 4.13 will error - Azure build agent defaults to v14.15 which is incompatible) - inputs: - versionSpec: 12.19 - - task: Npm@1 - displayName: npm custom - inputs: - command: custom - workingDir: LearningHub.Nhs.WebUI - verbose: false - customCommand: install -f - - task: Npm@1 - displayName: run webpack build - inputs: - command: custom - workingDir: LearningHub.Nhs.WebUI - verbose: false - customCommand: run build - - task: NuGetToolInstaller@1 - displayName: Use NuGet 5.8 - inputs: - versionSpec: 5.8 - - task: NuGetCommand@2 - displayName: NuGet restore - inputs: - feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 - - task: DotNetCoreCLI@2 - displayName: Restore - inputs: - command: restore - projects: $(BuildParameters.RestoreBuildProjects) - - task: DotNetCoreCLI@2 - displayName: Build - inputs: - projects: $(BuildParameters.RestoreBuildProjects) - arguments: --configuration $(BuildConfiguration) - - task: DotNetCoreCLI@2 - displayName: Test - enabled: False - inputs: - command: test - projects: $(BuildParameters.TestProjects) - arguments: --configuration $(BuildConfiguration) - - task: DotNetCoreCLI@2 - displayName: Publish WebUI - inputs: - command: publish - publishWebProjects: false - projects: '**/*LearningHub.Nhs.WebUI.csproj' - arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/WebUI - zipAfterPublish: True - - task: PublishBuildArtifacts@1 - displayName: Publish Artifact WebUI - condition: succeededOrFailed() - inputs: - PathtoPublish: $(Build.ArtifactStagingDirectory)/WebUI - ArtifactName: WebUI - TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' - - task: DotNetCoreCLI@2 - displayName: Publish AdminUI - inputs: - command: publish - publishWebProjects: false - projects: '**/*LearningHub.Nhs.AdminUI.csproj' - arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/AdminUI - zipAfterPublish: True - - task: PublishBuildArtifacts@1 - displayName: Publish Artifact AdminUI - condition: succeededOrFailed() - inputs: - PathtoPublish: $(Build.ArtifactStagingDirectory)/AdminUI - ArtifactName: AdminUI - TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' - - task: DotNetCoreCLI@2 - displayName: Publish WebAPI - inputs: - command: publish - publishWebProjects: false - projects: '**/*LearningHub.Nhs.Api.csproj' - arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/WebAPI - zipAfterPublish: True - - task: PublishBuildArtifacts@1 - displayName: 'Publish Artifact WebAPI ' - condition: succeededOrFailed() - inputs: - PathtoPublish: $(Build.ArtifactStagingDirectory)/WebAPI - ArtifactName: WebAPI - TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' -...