1

I'm trying to use SOPS to decrypt a file using Jenkins, using this command:

sops -k -d  mysecret.yaml > out

But then I get this output and it waits till forever:

Vim: Warning: Output is not to a terminal

I've tried to export some env. vars, but I ended up with the same result

export TERM=xterm-256color
export EDITOR="/usr/bin/vim"

Can anyone please explain to me why that happens?

Update:

By using sops -k -d mysecret.yaml --output OUT with the above env. vars and now I can see file being decrypted but still vim process is not finish and the task stays forever.

Haitham00n
  • 31
  • 4

1 Answers1

2

I shouldn't use -k as a command argument after removing KMS ARN and replacing it with export SOPS_KMS_ARN="arn:aws:kms:us-east-1:xxxxxx:key/xxx-xxxx-xxxxx"

Correct command is:

    export SOPS_KMS_ARN="arn:aws:kms:us-east-1:xxxxxx:key/xxx-xxxx-xxxxx
    sops  -d rsi-tls-cert.yaml | kubectl apply -f -
    
Haitham00n
  • 31
  • 4