You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

18 lines
444 B

#!/bin/bash
OPTS=(
host
port
connection-security
auth-method
)
for var in "${OPTS[@]}"; do
value=$(options-get "$var") && relation-set "$var" "$value" || exit 1
case "$var:$value" in
auth-method:password)
login=$(options-get "login") && relation-set login "$login" || exit 1
password=$(options-get "password") && relation-set password "$password" || exit 1
;;
esac
done