Commit 41b2e624 authored by Rémy Coutable's avatar Rémy Coutable Committed by Albert Salim

Use a dedicated project access token for CI scripts

Signed-off-by: default avatarRémy Coutable <remy@rymai.me>
parent 64a920f2
......@@ -10,7 +10,8 @@ class CancelPipeline
DEFAULT_OPTIONS = {
project: ENV['CI_PROJECT_ID'],
pipeline_id: ENV['CI_PIPELINE_ID'],
api_token: ENV['GITLAB_BOT_MULTI_PROJECT_PIPELINE_POLLING_TOKEN']
# Default to "CI scripts API usage" at https://gitlab.com/gitlab-org/gitlab/-/settings/access_tokens
api_token: ENV['PROJECT_TOKEN_FOR_CI_SCRIPTS_API_USAGE']
}.freeze
def initialize(options)
......
......@@ -11,7 +11,8 @@ require 'net/http'
class ArtifactFinder
DEFAULT_OPTIONS = {
project: ENV['CI_PROJECT_ID'],
api_token: ENV['GITLAB_BOT_MULTI_PROJECT_PIPELINE_POLLING_TOKEN']
# Default to "CI scripts API usage" at https://gitlab.com/gitlab-org/gitlab/-/settings/access_tokens
api_token: ENV['PROJECT_TOKEN_FOR_CI_SCRIPTS_API_USAGE']
}.freeze
def initialize(options)
......
......@@ -11,7 +11,8 @@ class JobFinder
pipeline_id: ENV['CI_PIPELINE_ID'],
pipeline_query: {},
job_query: {},
api_token: ENV['GITLAB_BOT_MULTI_PROJECT_PIPELINE_POLLING_TOKEN']
# Default to "CI scripts API usage" at https://gitlab.com/gitlab-org/gitlab/-/settings/access_tokens
api_token: ENV['PROJECT_TOKEN_FOR_CI_SCRIPTS_API_USAGE']
}.freeze
def initialize(options)
......
......@@ -10,7 +10,8 @@ class PlayJob
DEFAULT_OPTIONS = {
project: ENV['CI_PROJECT_ID'],
pipeline_id: ENV['CI_PIPELINE_ID'],
api_token: ENV['GITLAB_BOT_MULTI_PROJECT_PIPELINE_POLLING_TOKEN']
# Default to "CI scripts API usage" at https://gitlab.com/gitlab-org/gitlab/-/settings/access_tokens
api_token: ENV['PROJECT_TOKEN_FOR_CI_SCRIPTS_API_USAGE']
}.freeze
def initialize(options)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment