From 78d4b04f040f0aa615e1fb6d94bfeef7bc9e7d31 Mon Sep 17 00:00:00 2001 From: Luke Heath Date: Tue, 30 May 2023 11:27:39 -0500 Subject: [PATCH] Add fleet-release approval for new gitops action repo (#11818) --- .../api/helpers/github-automations/get-is-pr-preapproved.js | 5 +++++ website/config/custom.js | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/website/api/helpers/github-automations/get-is-pr-preapproved.js b/website/api/helpers/github-automations/get-is-pr-preapproved.js index 0783d50b81..c7bfb8b0c3 100644 --- a/website/api/helpers/github-automations/get-is-pr-preapproved.js +++ b/website/api/helpers/github-automations/get-is-pr-preapproved.js @@ -30,6 +30,7 @@ module.exports = { require('assert')(sails.config.custom.githubRepoDRIByPath); require('assert')(sails.config.custom.confidentialGithubRepoDRIByPath); + require('assert')(sails.config.custom.fleetMdmGitopsGithubRepoDRIByPath); require('assert')(sails.config.custom.githubAccessToken); let DRI_BY_PATH = sails.config.custom.githubRepoDRIByPath; @@ -38,6 +39,10 @@ module.exports = { DRI_BY_PATH = sails.config.custom.confidentialGithubRepoDRIByPath; } + if (repo === 'fleet-mdm-gitops') { + DRI_BY_PATH = sails.config.custom.fleetMdmGitopsGithubRepoDRIByPath; + } + let owner = 'fleetdm'; let baseHeaders = { 'User-Agent': 'Fleet auto-approve', diff --git a/website/config/custom.js b/website/config/custom.js index 8a701a3d4d..89ef99b954 100644 --- a/website/config/custom.js +++ b/website/config/custom.js @@ -163,6 +163,10 @@ module.exports.custom = { }, + fleetMdmGitopsGithubRepoDRIByPath: { + '/': ['lukeheath'] + }, + // The version of osquery to use when generating schema docs // (both in Fleet's query console and on fleetdm.com) versionOfOsquerySchemaToUseWhenGeneratingDocumentation: '5.8.1',