From 51c648206523ce19caee9df4dfeb59fc986b418d Mon Sep 17 00:00:00 2001 From: dvirlabs Date: Sun, 29 Jun 2025 07:15:23 +0300 Subject: [PATCH] Add github token --- .woodpecker.yml | 5 ++++- automation/alerts/generate_monitor_workflow.py | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.woodpecker.yml b/.woodpecker.yml index 45351d0..5390fe9 100644 --- a/.woodpecker.yml +++ b/.woodpecker.yml @@ -36,4 +36,7 @@ steps: commands: - apk add --no-cache git curl bash - pip install pyyaml requests - - python3 automation/alerts/generate_monitor_workflow.py \ No newline at end of file + - python3 automation/alerts/generate_monitor_workflow.py + environment: + GITHUB_TOKEN: + from_secret: GITHUB_TOKEN \ No newline at end of file diff --git a/automation/alerts/generate_monitor_workflow.py b/automation/alerts/generate_monitor_workflow.py index 510f285..3369503 100644 --- a/automation/alerts/generate_monitor_workflow.py +++ b/automation/alerts/generate_monitor_workflow.py @@ -7,7 +7,7 @@ REPOS = { "dev-tools": "https://git.dvirlabs.com/dvirlabs/dev-tools.git", "infra": "https://git.dvirlabs.com/dvirlabs/infra.git" } -GITHUB_REPO = "git@github.com:dvirh/lab-monitor.git" +GITHUB_REPO = f"https://{os.getenv('GITHUB_TOKEN')}@github.com/dvirh/lab-monitor.git" BASE_DIR = "./repos" WORKFLOW_FILE = "./repos/lab-monitor/.github/workflows/monitor.yml"