-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to use it? #1
Comments
I updated the readme file, check it out and tell if you still have questions. |
Great. But it says "connman-dispatcher -p /etc/connman-dispatcher" |
When you run it with a default systemd unit file, it is run like this:
so every script in Did I answer your question, because I'm not sure if I understood you correctly. |
Thanks. I did some tests, and it indeed runs some simple scripts, like that one: #! /bin/sh
up() {
touch /lalalala
}
down() {
touch /lalala2
}
state="$1"
case $state in
up)
up
;;
down)
down
;;
esac but it doesn't run a more complex script, like this one: #! /bin/sh
up() {
echo secretpass | sshfs [email protected]:public_html /mnt/larum/ -p 16969 -o workaround=rename -o password_stdin
}
down() {
fusermount -u /mnt/larum/
}
state="$1"
case $state in
up)
up
;;
down)
down
;;
esac or #! /bin/sh
up() {
mount -tbitcasa [email protected] /mnt/bitcasa -o password=test123
}
down() {
umount /mnt/bitcasa
umount /mnt/bitcasa2
}
state="$1"
case $state in
up)
up
;;
down)
down
;;
esac Do you know why it could be so? |
If you run it using systemd, you can check it's output by running:
And of course, you can just run it from the command line and see the output immediately. |
It seems like a great tool, but there is no information how to use it. In arch, starting the service creates the folder "/etc/connman-dispatcher" which I suppose is where the scripts should go.
But how are they supposed to be named? In what folders? There must be some way for the service to differentiate between scripts that are to be run on connect, and on disconnect, etc.
Please, provide some info.
The text was updated successfully, but these errors were encountered: