getsops / getsops/sops

'az' is not recognized as an internal or external command

Open
#1,430 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
23.1k
Forks
1.1k
Avg merge
1d 11h
Merged PRs (30d)
9

Description

I am using sops with Terraform and have the same issue as in #818

│ Error: Failed to get the data key required to decrypt the SOPS file.
│
│ Group 0: FAILED
│   https://xxxxxxxx.vault.azure.net/keys/sops-key/xxxxxxxxxxxx: FAILED
│     - | Invoking Azure CLI failed with the following error: 'az' is
│       | not recognized as an internal or external command,
│       | operable program or batch file.
│
│
│ Recovery failed because no master key was able to decrypt the file. In
│ order for SOPS to recover the file, at least one key has to be successful,
│ but none were.

Calling az works fine and

hich az
/c/Program Files/Microsoft SDKs/Azure/CLI2/wbin/az

The difference to [#818] is, that az is installed with msi not SOPS

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the related behavior in issue #818 and reproduce the Azure CLI invocation on Windows with Azure CLI installed via MSI. The work is done when SOPS can invoke az successfully in this setup and the reported decryption error no longer occurs.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, go
Domain
cloud, security
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.