diff --git a/.github/dependabot.yml b/.github/dependabot.yml deleted file mode 100644 index 93b3c8246e..0000000000 --- a/.github/dependabot.yml +++ /dev/null @@ -1,99 +0,0 @@ -# Configuration based on https://help.github.com/en/github/administering-a-repository/configuration-options-for-dependency-updates - -version: 2 -updates: - - package-ecosystem: "nuget" - directory: "/" - schedule: - interval: "daily" - time: "09:00" - timezone: "America/Los_Angeles" - open-pull-requests-limit: 30 - - - package-ecosystem: "docker" - directory: "/" - schedule: - interval: "daily" - time: "09:00" - timezone: "America/Los_Angeles" - open-pull-requests-limit: 30 - - - package-ecosystem: "docker" - directory: "/docker/sql" - schedule: - interval: "daily" - time: "09:00" - timezone: "America/Los_Angeles" - open-pull-requests-limit: 30 - - - package-ecosystem: "docker" - directory: "/src/Microsoft.Health.Dicom.Functions.App/Docker" - schedule: - interval: "daily" - time: "09:00" - timezone: "America/Los_Angeles" - open-pull-requests-limit: 30 - - - package-ecosystem: "docker" - directory: "/src/Microsoft.Health.Dicom.Web" - schedule: - interval: "daily" - time: "09:00" - timezone: "America/Los_Angeles" - open-pull-requests-limit: 30 - - - package-ecosystem: "docker" - directory: "/converter/dicom-cast/src/Microsoft.Health.DicomCast.Hosting" - schedule: - interval: "daily" - time: "09:00" - timezone: "America/Los_Angeles" - open-pull-requests-limit: 30 - - - package-ecosystem: "docker" - directory: "/tools/uploader-function/src/DicomUploaderFunction" - schedule: - interval: "daily" - time: "09:00" - timezone: "America/Los_Angeles" - open-pull-requests-limit: 30 - - - package-ecosystem: "github-actions" - directory: "/" - schedule: - interval: "daily" - time: "09:00" - timezone: "America/Los_Angeles" - open-pull-requests-limit: 30 - - - package-ecosystem: "npm" - directory: "/tools/dicom-web-electron" - schedule: - interval: "daily" - time: "09:00" - timezone: "America/Los_Angeles" - open-pull-requests-limit: 30 - - - package-ecosystem: "nuget" - directory: "/converter/dicom-cast" - schedule: - interval: "daily" - time: "09:00" - timezone: "America/Los_Angeles" - open-pull-requests-limit: 30 - - - package-ecosystem: "nuget" - directory: "/tools/dicom-auth-test/Microsoft.Health.Web.Dicom.Tool" - schedule: - interval: "daily" - time: "09:00" - timezone: "America/Los_Angeles" - open-pull-requests-limit: 30 - - - package-ecosystem: "nuget" - directory: "/tools/uploader-function" - schedule: - interval: "daily" - time: "09:00" - timezone: "America/Los_Angeles" - open-pull-requests-limit: 30 diff --git a/.github/workflows/combine-dependabot-prs.yml b/.github/workflows/combine-dependabot-prs.yml deleted file mode 100644 index b024d423e9..0000000000 --- a/.github/workflows/combine-dependabot-prs.yml +++ /dev/null @@ -1,160 +0,0 @@ -# Component Source: https://github.com/hrvey/combine-prs-workflow/ -name: 'Combine Dependabot PRs' - -# Controls when the action will run - in this case triggered manually -on: - workflow_dispatch: - inputs: - branchPrefix: - description: 'Branch prefix to find combinable PRs based on' - required: true - default: 'dependabot' - mustBeGreen: - description: 'Only combine PRs that are green (status is success)' - required: true - default: true - combineBranchName: - description: 'Name of the branch to combine PRs into' - required: true - default: 'combine-prs-branch' - ignoreLabel: - description: 'Exclude PRs with this label' - required: true - default: 'nocombine' - -# A workflow run is made up of one or more jobs that can run sequentially or in parallel -jobs: - # This workflow contains a single job called "combine-prs" - combine-prs: - # The type of runner that the job will run on - runs-on: ubuntu-latest - - # Steps represent a sequence of tasks that will be executed as part of the job - steps: - - uses: actions/github-script@v6 - id: fetch-branch-names - name: Fetch branch names - with: - github-token: ${{secrets.GITHUB_TOKEN}} - script: | - const pulls = await github.paginate('GET /repos/:owner/:repo/pulls', { - owner: context.repo.owner, - repo: context.repo.repo - }); - branches = []; - prs = []; - base_branch = null; - for (const pull of pulls) { - const branch = pull['head']['ref']; - console.log('Pull for branch: ' + branch); - if (branch.startsWith('${{ github.event.inputs.branchPrefix }}')) { - console.log('Branch matched: ' + branch); - statusOK = true; - if(${{ github.event.inputs.mustBeGreen }}) { - console.log('Checking green status: ' + branch); - const statuses = await github.request('GET /repos/{owner}/{repo}/commits/{ref}/status', { - owner: context.repo.owner, - repo: context.repo.repo, - ref: branch - }); - - if(statuses.length > 0) { - const latest_status = statuses[0]['state']; - console.log('Validating status: ' + latest_status); - if(latest_status != 'success') { - console.log('Discarding ' + branch + ' with status ' + latest_status); - statusOK = false; - } - } - - console.log('Checking check suites: ' + branch); - const checks = await github.paginate('GET /repos/{owner}/{repo}/commits/{ref}/check-suites', { - owner: context.repo.owner, - repo: context.repo.repo, - ref: branch - }); - - for (const check of checks) { - const isSuccess = (check.status == 'completed' && check.conclusion == 'success') - const isDependabot = check.app.slug == 'dependabot' - if (!isSuccess && !isDependabot) { - console.log('Discarding ' + branch + ' with check suite ' + check.url); - statusOK = false; - } - } - } - - console.log('Checking labels: ' + branch); - const labels = pull['labels']; - for(const label of labels) { - const labelName = label['name']; - console.log('Checking label: ' + labelName); - if(labelName == '${{ github.event.inputs.ignoreLabel }}') { - console.log('Discarding ' + branch + ' with label ' + labelName); - statusOK = false; - } - } - if (statusOK) { - console.log('Adding branch to array: ' + branch); - branches.push(branch); - prs.push('#' + pull['number'] + ' ' + pull['title']); - base_branch = pull['base']['ref']; - } - } - } - - if (branches.length == 0) { - core.setFailed('No PRs/branches matched criteria'); - return; - } - - core.setOutput('base-branch', base_branch); - core.setOutput('prs-string', prs.join('\n')); - - combined = branches.join(' ') - console.log('Combined: ' + combined); - return combined - # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it - - uses: actions/checkout@v3.5.3 - with: - fetch-depth: 0 - # Creates a branch with other PR branches merged together - - name: Created combined branch - env: - BASE_BRANCH: ${{ steps.fetch-branch-names.outputs.base-branch }} - BRANCHES_TO_COMBINE: ${{ steps.fetch-branch-names.outputs.result }} - COMBINE_BRANCH_NAME: ${{ github.event.inputs.combineBranchName }} - run: | - echo "$BRANCHES_TO_COMBINE" - sourcebranches="${BRANCHES_TO_COMBINE%\"}" - sourcebranches="${sourcebranches#\"}" - - basebranch="${BASE_BRANCH%\"}" - basebranch="${basebranch#\"}" - - git config pull.rebase false - git config user.name github-actions - git config user.email github-actions@github.com - - git branch $COMBINE_BRANCH_NAME $basebranch - git checkout $COMBINE_BRANCH_NAME - git pull origin $sourcebranches --no-edit - git push origin $COMBINE_BRANCH_NAME - # Creates a PR with the new combined branch - - uses: actions/github-script@v6 - name: Create Combined Pull Request - env: - PRS_STRING: ${{ steps.fetch-branch-names.outputs.prs-string }} - with: - github-token: ${{secrets.GITHUB_TOKEN}} - script: | - const prString = process.env.PRS_STRING; - const body = 'This PR was created by the Combine PRs action by combining the following PRs:\n' + prString; - await github.pulls.create({ - owner: context.repo.owner, - repo: context.repo.repo, - title: 'Combined Dependabot PR', - head: '${{ github.event.inputs.combineBranchName }}', - base: '${{ steps.fetch-branch-names.outputs.base-branch }}', - body: body - }); diff --git a/Directory.Build.props b/Directory.Build.props index e17f15eefe..ade1993cf2 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -2,23 +2,17 @@ $(AllowedOutputExtensionsInPackageBuildOutputFolder);.pdb - 2.21.0 Microsoft Health Team Microsoft Corporation Copyright © Microsoft Corporation. All rights reserved. true true true - 2.0.55 true - 6.2.119 true - 4.3.0 - 6.32.0 Latest net6.0 true - 1.5.1 MIT Microsoft Health true diff --git a/Directory.Packages.props b/Directory.Packages.props index 18240634a3..1f5162db94 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -15,16 +15,16 @@ - - - + + + - - - + + + @@ -59,30 +59,30 @@ - + - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + - + @@ -91,10 +91,10 @@ - - - - + + + + @@ -103,7 +103,7 @@ - + diff --git a/renovate.json b/renovate.json new file mode 100644 index 0000000000..af92c59658 --- /dev/null +++ b/renovate.json @@ -0,0 +1,96 @@ +{ + "$schema": "https://docs.renovatebot.com/renovate-schema.json", + "extends": [ + ":dependencyDashboard", + ":semanticPrefixFixDepsChoreOthers", + "group:dotNetCore", + "group:monorepos", + "group:recommended", + "replacements:all", + "workarounds:all" + ], + "labels": [ + "dependencies" + ], + "packageRules": [ + { + "groupName": "ApplicationInsights", + "matchPackagePatterns": [ + "ApplicationInsights" + ] + }, + { + "groupName": "Dotnet", + "matchPackageNames": [ + "dotnet-sdk", + "mcr.microsoft.com/dotnet/aspnet", + "mcr.microsoft.com/dotnet/sdk" + ] + }, + { + "excludePackagePrefixes": [ + "Microsoft.Health.Fhir." + ], + "groupName": "Healthcare Shared Components", + "matchPackagePrefixes": [ + "Microsoft.Health." + ] + }, + { + "groupName": "Hl7", + "matchPackagePrefixes": [ + "Hl7.Fhir." + ] + }, + { + "groupName": "IdentityModel.Tokens", + "matchPackagePatterns": [ + "IdentityModel.Tokens" + ] + }, + { + "groupName": "IdentityServer4", + "matchPackagePrefixes": [ + "IdentityServer4" + ] + }, + { + "groupName": "Microsoft.AspNetCore.Mvc.Versioning", + "matchPackagePrefixes": [ + "Microsoft.AspNetCore.Mvc.Versioning" + ] + }, + { + "groupName": "Microsoft FHIR", + "matchPackagePrefixes": [ + "Microsoft.Health.Fhir." + ] + }, + { + "groupName": "OpenTelemetry", + "matchPackagePrefixes": [ + "OpenTelemetry" + ] + }, + { + "groupName": "Swashbuckle.AspNetCore", + "matchPackagePrefixes": [ + "Swashbuckle.AspNetCore." + ] + }, + { + "groupName": "System.CommandLine", + "matchPackagePrefixes": [ + "System.CommandLine" + ] + }, + { + "groupName": "XUnit", + "matchPackagePrefixes": [ + "xunit" + ] + } + ], + "prConcurrentLimit": 0, + "prHourlyLimit": 0 +} diff --git a/src/Microsoft.Health.Dicom.SqlServer/Microsoft.Health.Dicom.SqlServer.csproj b/src/Microsoft.Health.Dicom.SqlServer/Microsoft.Health.Dicom.SqlServer.csproj index 9fc1ee3472..91c11d323e 100644 --- a/src/Microsoft.Health.Dicom.SqlServer/Microsoft.Health.Dicom.SqlServer.csproj +++ b/src/Microsoft.Health.Dicom.SqlServer/Microsoft.Health.Dicom.SqlServer.csproj @@ -24,7 +24,7 @@ - + @@ -75,8 +75,10 @@ - - + + + +