diff options
author | Lauri Ojansivu <x@xet7.org> | 2018-02-22 02:17:52 +0200 |
---|---|---|
committer | Lauri Ojansivu <x@xet7.org> | 2018-02-22 02:17:52 +0200 |
commit | 7498dba32c8fbf460e04af49d5fb32dc5e63ed8b (patch) | |
tree | 19d7cbfa45e4de37142e6a2dcede722b3f09a89d /snap-src/bin/wekan-help | |
parent | 26f66f3cf05d3ab3dd633d02399cea5aa5a99c00 (diff) | |
parent | d374cd2f813e5e88b0e10b6fe851565b36e5ab0a (diff) | |
download | wekan-7498dba32c8fbf460e04af49d5fb32dc5e63ed8b.tar.gz wekan-7498dba32c8fbf460e04af49d5fb32dc5e63ed8b.tar.bz2 wekan-7498dba32c8fbf460e04af49d5fb32dc5e63ed8b.zip |
Merge branch 'kubiko-devel' into devel
Diffstat (limited to 'snap-src/bin/wekan-help')
-rwxr-xr-x | snap-src/bin/wekan-help | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/snap-src/bin/wekan-help b/snap-src/bin/wekan-help new file mode 100755 index 00000000..a498b9b9 --- /dev/null +++ b/snap-src/bin/wekan-help @@ -0,0 +1,53 @@ +#!/bin/bash + +# first read settings +source $SNAP/bin/wekan-read-settings &>/dev/null +if [ "$CADDY_ENABLED" = "true" ]; then + # tweak port nunmber as it has been remapped + export PORT=${CADDY_PORT} &>/dev/null +fi + +echo -e "Wekan: The open-source Trello-like kanban.\n" +echo -e "Make sure you have connected all interfaces, check more by calling $ snap interfaces" +echo -e "\n" +echo -e "${SNAP_NAME} has multiple services, to check status/restart/stop use systemctl" +echo -e "mongodb service:" +echo -e "\t$ sudo systemctl status/start/stop/restart snap.$SNAP_NAME.mongodb" +echo -e "wekan service" +echo -e "\t$ sudo systemctl status/start/stop/restart snap.$SNAP_NAME.wekan" +echo -e "Optional caddy service" +echo -e "\t$ sudo systemctl status/start/stop/restart snap.$SNAP_NAME.caddy" +echo -e "\n" +echo -e "To make backup of wekan's database use: $ ${SNAP_NAME}.database-backup [backup file]" +echo -e "\t backup file is optional parameter, if not passed backup is created in directory:" +echo -e "\t\t${SNAP_COMMON}/db-backups" +echo -e "To list existing backups in default directory: $ ${SNAP_NAME}.database-list-backups" +echo -e "To restore wekan's database use: ${SNAP_NAME}.database-restore <path to backup>" +echo -e "\n" +echo -e "wekan can be configured to share mongodb with other services using content interface" +echo -e "\t-sharing mongodb from $SNAP_NAME to other snap(s):" +echo -e "\t\t-connect mongodb-slot with plug from corresponding snap(s)" +echo -e "\t\t-configure corresponding service to use mongodb unix socket in shared directory, socket file name is: mongodb-$MONGODB_PORT.sock" +echo -e "\t-sharing mongodb from other snap to $SNAP_NAME:" +echo -e "\t\t-connect mongodb-plug with slot from snap providing mongodb" +echo -e "\t\t-disable mongodb in $SNAP_NAME by calling: $ snap set $SNAP_NAME set disable-mongodb='true'" +echo -e "\t\t-set mongodb-bind-unix-socket to point to serving mongodb. Use relative path inside shared directory, e.g run/mongodb-27017.sock" +echo -e "\n" +# parse config file for supported settings keys +echo -e "wekan supports settings keys" +echo -e "values can be changed by calling\n$ snap set $SNAP_NAME <key name>='<key value>'" +echo -e "list of supported keys:" +for key in ${keys[@]} +do + default_value="DEFAULT_$key" + description="DESCRIPTION_$key" + snappy_key="KEY_$key" + echo -e "\t${!snappy_key}: ${!description}" + if [ "x" == "x${!key}" ]; then + echo -e "\t\tNo value set, using default value: '${!default_value}'" + else + echo -e "\t\tCurrent value set to: '${!key}', (default value: '${!default_value}')" + fi +done + +echo -e "\n!!!! Some changes result in restart of some or all services, use with caution !!!!!" |