From 45bba1afb20e9ace5ac9f6e310205a5934aaf5df Mon Sep 17 00:00:00 2001 From: Jakub Krajewski Date: Mon, 15 Jul 2024 11:01:56 +0200 Subject: [PATCH] Add read-all perm. Generate run_id instead of taking from env variable --- .github/workflows/integrationtests.yml | 3 ++- catalystwan/integration_tests/base.py | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/integrationtests.yml b/.github/workflows/integrationtests.yml index 3a1526c0..31d59abe 100644 --- a/.github/workflows/integrationtests.yml +++ b/.github/workflows/integrationtests.yml @@ -3,6 +3,8 @@ on: branches: - dev-uxmt +permissions: read-all + # This ensures only one job runs at a time across all workflows concurrency: group: integration_tests @@ -18,7 +20,6 @@ jobs: VMANAGE_USERNAME: ${{ secrets.VMANAGE_USERNAME }} VMANAGE_PASSWORD: ${{ secrets.VMANAGE_PASSWORD }} VMANAGE_PORT: ${{ secrets.VMANAGE_PORT }} - RUN_ID: ${{ github.event.pull_request.number }} CATALYSTWAN_DEVEL: true defaults: run: diff --git a/catalystwan/integration_tests/base.py b/catalystwan/integration_tests/base.py index 2467ee7a..d4fc66dd 100644 --- a/catalystwan/integration_tests/base.py +++ b/catalystwan/integration_tests/base.py @@ -3,7 +3,7 @@ import os import unittest from typing import Union -from uuid import UUID +from uuid import UUID, uuid4 from packaging.version import Version # type: ignore @@ -22,7 +22,7 @@ logger = logging.getLogger(__name__) -RUN_ID: int = int(os.environ.get("RUN_ID", 0)) +RUN_ID: str = str(uuid4())[:4] def create_session() -> ManagerSession: