use declare for description variable
This commit is contained in:
@@ -3,7 +3,7 @@ set -eo pipefail; [[ $DOKKU_TRACE ]] && set -x
|
||||
source "$PLUGIN_CORE_AVAILABLE_PATH/common/functions"
|
||||
|
||||
is_ssl_enabled() {
|
||||
local desc="returns 0 if ssl is enabled for given app"
|
||||
declare desc="returns 0 if ssl is enabled for given app"
|
||||
local APP=$1; verify_app_name "$APP"
|
||||
local APP_SSL_PATH="$DOKKU_ROOT/$APP/tls"
|
||||
|
||||
@@ -15,7 +15,7 @@ is_ssl_enabled() {
|
||||
}
|
||||
|
||||
get_ssl_hostnames() {
|
||||
local desc="returns a string of ssl hostnames extracted from an app's ssl certificate"
|
||||
declare desc="returns a string of ssl hostnames extracted from an app's ssl certificate"
|
||||
local APP=$1; verify_app_name "$APP"
|
||||
local SSL_PATH="$DOKKU_ROOT/$APP/tls"
|
||||
|
||||
|
||||
@@ -5,13 +5,13 @@ source "$PLUGIN_AVAILABLE_PATH/certs/functions"
|
||||
source "$PLUGIN_AVAILABLE_PATH/nginx-vhosts/functions"
|
||||
|
||||
is_tar_import() {
|
||||
local desc="determines if we have STDIN open in an attempt to detect a streamed tar import"
|
||||
declare desc="determines if we have STDIN open in an attempt to detect a streamed tar import"
|
||||
[[ -t 0 ]] && return 1
|
||||
return 0
|
||||
}
|
||||
|
||||
is_file_import() {
|
||||
local desc="determines if we have passed in a file and key path for a file import"
|
||||
declare desc="determines if we have passed in a file and key path for a file import"
|
||||
local CRT_FILE="$1"
|
||||
local KEY_FILE="$2"
|
||||
|
||||
@@ -29,7 +29,7 @@ is_file_import() {
|
||||
}
|
||||
|
||||
certs_set() {
|
||||
local desc="imports an SSL cert/key combo either on STDIN via a tarball or from specified cert/key filenames"
|
||||
declare desc="imports an SSL cert/key combo either on STDIN via a tarball or from specified cert/key filenames"
|
||||
local cmd="$1"
|
||||
[[ -z $2 ]] && dokku_log_fail "Please specify an app to run the command on"
|
||||
verify_app_name "$2"
|
||||
|
||||
@@ -5,7 +5,7 @@ source "$PLUGIN_AVAILABLE_PATH/domains/functions"
|
||||
source "$PLUGIN_AVAILABLE_PATH/nginx-vhosts/functions"
|
||||
|
||||
certs_generate_cmd() {
|
||||
local desc="generates a self-signed SSL certificate/key combo"
|
||||
declare desc="generates a self-signed SSL certificate/key combo"
|
||||
local cmd="certs:generate"
|
||||
[[ -z $2 ]] && dokku_log_fail "Please specify an app to run the command on"
|
||||
verify_app_name "$2"
|
||||
|
||||
@@ -4,7 +4,7 @@ source "$PLUGIN_CORE_AVAILABLE_PATH/common/functions"
|
||||
source "$PLUGIN_AVAILABLE_PATH/certs/functions"
|
||||
|
||||
certs_info_cmd() {
|
||||
local desc="prints SSL certificate info for app"
|
||||
declare desc="prints SSL certificate info for app"
|
||||
local cmd="certs:info"
|
||||
[[ -z $2 ]] && dokku_log_fail "Please specify an app to run the command on"
|
||||
verify_app_name "$2"
|
||||
|
||||
@@ -3,7 +3,7 @@ set -eo pipefail; [[ $DOKKU_TRACE ]] && set -x
|
||||
source "$PLUGIN_CORE_AVAILABLE_PATH/common/functions"
|
||||
|
||||
certs_remove_cmd() {
|
||||
local desc="removes SSL cert/key from specified app"
|
||||
declare desc="removes SSL cert/key from specified app"
|
||||
local cmd="certs:remove"
|
||||
[[ -z $2 ]] && dokku_log_fail "Please specify an app to run the command on"
|
||||
verify_app_name "$2"
|
||||
|
||||
Reference in New Issue
Block a user