Skip to content

Commit

Permalink
fix: non-zero exit on --logs and handle no opts (#5006)
Browse files Browse the repository at this point in the history
* fix: non-zero exit on --logs and handle no opts

* chore: update cwctl version + add utm_source
  • Loading branch information
vishnu-narayanan committed Jul 8, 2022
1 parent 49d08a6 commit 1bb9556
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
2 changes: 1 addition & 1 deletion VERSION_CWCTL
@@ -1 +1 @@
2.0.7
2.0.8
17 changes: 9 additions & 8 deletions deployment/setup_20.04.sh
Expand Up @@ -2,7 +2,7 @@

# Description: Install and manage a Chatwoot installation.
# OS: Ubuntu 20.04 LTS
# Script Version: 2.0.7
# Script Version: 2.0.8
# Run this script as root

set -eu -o errexit -o pipefail -o noclobber -o nounset
Expand All @@ -19,11 +19,11 @@ fi
# option --output/-o requires 1 argument
LONGOPTS=console,debug,help,install:,logs:,restart,ssl,upgrade,webserver,version
OPTIONS=cdhi:l:rsuwv
CWCTL_VERSION="2.0.7"
CWCTL_VERSION="2.0.8"
pg_pass=$(head /dev/urandom | tr -dc A-Za-z0-9 | head -c 15 ; echo '')

# if user does not specify an option
if [ -z "$1" ]; then
if [ "$#" -eq 0 ]; then
echo "No options specified. Use --help to learn more."
exit 1
fi
Expand Down Expand Up @@ -436,7 +436,7 @@ function ssl_success_message() {
Woot! Woot!! Chatwoot server installation is complete.
The server will be accessible at https://$domain_name
Join the community at https://chatwoot.com/community
Join the community at https://chatwoot.com/community?utm_source=cwctl
***************************************************************************
EOF
Expand Down Expand Up @@ -546,9 +546,9 @@ Woot! Woot!! Chatwoot server installation is complete.
The server will be accessible at http://$public_ip:3000
To configure a domain and SSL certificate, follow the guide at
https://www.chatwoot.com/docs/deployment/deploy-chatwoot-in-linux-vm
https://www.chatwoot.com/docs/deployment/deploy-chatwoot-in-linux-vm?utm_source=cwctl
Join the community at https://chatwoot.com/community
Join the community at https://chatwoot.com/community?utm_source=cwctl
***************************************************************************
EOF
Expand Down Expand Up @@ -634,7 +634,7 @@ Exit status:
Returns 0 if successful; non-zero otherwise.
Report bugs at https://github.com/chatwoot/chatwoot/issues
Get help, https://chatwoot.com/community
Get help, https://chatwoot.com/community?utm_source=cwctl
EOF
}
Expand All @@ -651,7 +651,8 @@ EOF
function get_logs() {
if [ "$SERVICE" == "worker" ]; then
journalctl -u chatwoot-worker.1.service -f
else
fi
if [ "$SERVICE" == "web" ]; then
journalctl -u chatwoot-web.1.service -f
fi
}
Expand Down

0 comments on commit 1bb9556

Please sign in to comment.