Add encrypting helper
This commit is contained in:
parent
d55edd7ddd
commit
bf5d867414
16
sbin/encrypt.sh
Executable file
16
sbin/encrypt.sh
Executable file
@ -0,0 +1,16 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -eu -o pipefail
|
||||
|
||||
# Usage
|
||||
# ./encrypt.sh mysecretname mysecretvalue
|
||||
|
||||
declare name="$1"
|
||||
declare secret="$2"
|
||||
|
||||
ansible-vault \
|
||||
encrypt_string \
|
||||
--vault-password-file ansible/.vault.sh \
|
||||
--name \
|
||||
"$name" \
|
||||
"$secret"
|
Reference in New Issue
Block a user