How do you set a password environment param?, do you have to unset it just after using so not giving enought time for anyone to track it?
I would do it like this.,,tell me please, If Im doing wrong or can be done in some better way.. , thanks.
(secrets.sh script picks a password from a secrets file)
Code: Select all
export RCLONE_CONFIG_PASS=$(sudo /home/user/scripts/secrets.sh XXYY6)
rclone sync source/ target/ &
sleep 1 && unset RCLONE_CONFIG_PASS
while ! -z $(pgrep -f /bin/rclone); do; sleep 1 && echo "wait for rclone task" ; done;