sops
sops copied to clipboard
SOPS cannot handle multi-line .env files
The parser that SOPS uses seems to have a different interpretation of what constitutes a dotenv file from what how bash views is. This relates in particular to encrypting/decrypt dotenvs that have multiline environement variables.
However, SOPS is not able to handle encrypting this file. Calling sops -e --pgp xxxxxxxx my-vars.env
will produce the following error:
Error unmarshalling file: invalid dotenv input line: some values
The parser is trying to interpret the second line of BAR (which is "some values") as another key-value pair, which does not work.
This is a pretty major inconsistency.