Skip to content

Commit

Permalink
PR checks without vault login
Browse files Browse the repository at this point in the history
  • Loading branch information
jyejare committed Sep 14, 2023
1 parent f328479 commit 80ba020
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ jobs:
for conffile in conf/*.yaml.template; do mv -- "$conffile" "${conffile%.yaml.template}.yaml"; done
cp broker_settings.yaml.example broker_settings.yaml
cp .env.example .env
# To skip vault login in pull request checks
sed 's/^#\s*VAULT_SECRET_ID_FOR_DYNACONF=/VAULT_SECRET_ID_FOR_DYNACONF=somesecret/' .env
- name: Pre Commit Checks
uses: pre-commit/[email protected]
Expand Down
2 changes: 1 addition & 1 deletion robottelo/utils/vault.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ def exec_vault_command(self, command: str, **kwargs):
def login(self, **kwargs):
if (
re.search(r'\s*#.*VAULT_SECRET_ID_FOR_DYNACONF', self.env_path.read_text())
and 'VAULT_SECRET_ID_FOR_DYNACONF' not in os.environ
or 'VAULT_SECRET_ID_FOR_DYNACONF' not in os.environ
):
if self.status(**kwargs).returncode != 0:
logger.warning(
Expand Down

0 comments on commit 80ba020

Please sign in to comment.