Skip to content

Commit

Permalink
check cwd
Browse files Browse the repository at this point in the history
  • Loading branch information
rlxdev committed Jan 15, 2025
1 parent 0e66447 commit 10b42fa
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions scubagoggles/run_rego.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,17 @@ def opa_eval(product_name: str,
'-d', str(utils_rego),
'--format=values']

debug = True

if debug:
# This "explain" option seems to do nothing...
command.append('--explain=full')

try:
cpe = subprocess.run(['powershell', 'pwd'], shell=True, capture_output=True)

log.warning('cwd: %s', cpe.stdout.decode())

log.warning('Running OPA: "%s"', ' '.join(command))

output = subprocess.run(command, capture_output=True, check=True)
Expand Down

0 comments on commit 10b42fa

Please sign in to comment.