domains:clear now removes ALL app domains
This commit is contained in:
1 parent
7b45131486
commit
b97086a8bd
6 files changed
+9
-10
No files matched your search
@@ -6,8 +6,8 @@
|
|||||||
```
|
```
|
||||||
domains:add <app> <domain> [<domain> ...] # Add domains to app
|
domains:add <app> <domain> [<domain> ...] # Add domains to app
|
||||||
domains:add-global <domain> [<domain> ...] # Add global domain names
|
domains:add-global <domain> [<domain> ...] # Add global domain names
|
||||||
domains:clear <app> # Clear all domains for app
|
domains:clear <app> # Remove all app domains
|
||||||
domains:clear-global # Clear global domain names
|
domains:clear-global # Remove all global domains
|
||||||
domains:disable <app> # Disable VHOST support
|
domains:disable <app> # Disable VHOST support
|
||||||
domains:enable <app> # Enable VHOST support
|
domains:enable <app> # Enable VHOST support
|
||||||
domains:remove <app> <domain> [<domain> ...] # Remove domains from app
|
domains:remove <app> <domain> [<domain> ...] # Remove domains from app
|
||||||
@@ -67,7 +67,7 @@ dokku domains:add node-js-app dokku.me
|
|||||||
# list custom domains for app
|
# list custom domains for app
|
||||||
dokku domains:report node-js-app
|
dokku domains:report node-js-app
|
||||||
|
|
||||||
# clear all custom domains for app
|
# delete all domains for app
|
||||||
dokku domains:clear node-js-app
|
dokku domains:clear node-js-app
|
||||||
|
|
||||||
# remove a custom domain from app
|
# remove a custom domain from app
|
||||||
|
|||||||
@@ -150,7 +150,7 @@ At this time, the following dokku commands are used to interact with a complete
|
|||||||
|
|
||||||
- `domains:add`: Adds a given domain to an app.
|
- `domains:add`: Adds a given domain to an app.
|
||||||
- triggers: `post-domains-update`
|
- triggers: `post-domains-update`
|
||||||
- `domains:clear`: Clears out an app's associated domains.
|
- `domains:clear`: Remove all app domains.
|
||||||
- triggers: `post-domains-update`
|
- triggers: `post-domains-update`
|
||||||
- `domains:disable`: Disables domains for an app.
|
- `domains:disable`: Disables domains for an app.
|
||||||
- triggers: `pre-disable-vhost`
|
- triggers: `pre-disable-vhost`
|
||||||
|
|||||||
@@ -24,9 +24,8 @@ fn-domains-clear-app() {
|
|||||||
local APP_VHOST_PATH="$DOKKU_ROOT/$APP/VHOST"
|
local APP_VHOST_PATH="$DOKKU_ROOT/$APP/VHOST"
|
||||||
|
|
||||||
rm -f "$APP_VHOST_PATH"
|
rm -f "$APP_VHOST_PATH"
|
||||||
domains_setup "$APP"
|
|
||||||
plugn trigger post-domains-update "$APP" "clear"
|
plugn trigger post-domains-update "$APP" "clear"
|
||||||
dokku_log_info1 "Cleared domains in $APP"
|
dokku_log_info1 "Deleted all domains for $APP"
|
||||||
}
|
}
|
||||||
|
|
||||||
fn-domains-disable() {
|
fn-domains-disable() {
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ fn-help-content() {
|
|||||||
cat <<help_content
|
cat <<help_content
|
||||||
domains:add <app> <domain> [<domain> ...], Add domains to app
|
domains:add <app> <domain> [<domain> ...], Add domains to app
|
||||||
domains:add-global <domain> [<domain> ...], Add global domain names
|
domains:add-global <domain> [<domain> ...], Add global domain names
|
||||||
domains:clear <app>, Clear all domains for app
|
domains:clear <app>, Remove all app domains
|
||||||
domains:clear-global, Clear global domain names
|
domains:clear-global, Clear global domain names
|
||||||
domains:disable <app>, Disable VHOST support
|
domains:disable <app>, Disable VHOST support
|
||||||
domains:enable <app>, Enable VHOST support
|
domains:enable <app>, Enable VHOST support
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ source "$PLUGIN_CORE_AVAILABLE_PATH/common/functions"
|
|||||||
source "$PLUGIN_AVAILABLE_PATH/domains/functions"
|
source "$PLUGIN_AVAILABLE_PATH/domains/functions"
|
||||||
|
|
||||||
cmd-domains-clear() {
|
cmd-domains-clear() {
|
||||||
declare desc="clear all app domains"
|
declare desc="remove all app domains"
|
||||||
declare cmd="domains:clear"
|
declare cmd="domains:clear"
|
||||||
[[ "$1" == "$cmd" ]] && shift 1
|
[[ "$1" == "$cmd" ]] && shift 1
|
||||||
declare APP="$1"
|
declare APP="$1"
|
||||||
|
|||||||
@@ -5,11 +5,11 @@ source "$PLUGIN_CORE_AVAILABLE_PATH/common/functions"
|
|||||||
source "$PLUGIN_AVAILABLE_PATH/domains/functions"
|
source "$PLUGIN_AVAILABLE_PATH/domains/functions"
|
||||||
|
|
||||||
cmd-domains-clear-global() {
|
cmd-domains-clear-global() {
|
||||||
declare desc="clear global domain names via command line"
|
declare desc="remove all global domains"
|
||||||
declare cmd="domains:clear-global"
|
declare cmd="domains:clear-global"
|
||||||
[[ "$1" == "$cmd" ]] && shift 1
|
[[ "$1" == "$cmd" ]] && shift 1
|
||||||
|
|
||||||
dokku_log_info1_quiet "Clearing global domains"
|
dokku_log_info1_quiet "Deleting global domains"
|
||||||
domains_clear_global "$@"
|
domains_clear_global "$@"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user