Skip to content
This repository was archived by the owner on Nov 9, 2022. It is now read-only.

Commit c065066

Browse files
committed
Fixed #799: allow non-local to be wiped without confirmation
1 parent 1326241 commit c065066

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

deploy/default.properties

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -226,6 +226,9 @@ rewrite-resolves-globally=
226226
# Environments recognized by Roxy
227227
environments=local,dev,prod
228228

229+
# Environments that can be wiped without confirmation
230+
wipe_environments=local
231+
229232
#
230233
# The Major version of ML server across your environments (6, 7, or 8). You can override
231234
# this value in build.properties if all of your servers are the same version

deploy/lib/server_config.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -941,7 +941,8 @@ def wipe
941941
@ml_password = @properties['ml.password']
942942
end
943943

944-
if @environment != "local"
944+
wipe_environments = (@properties['ml.wipe-environments'] || 'local').split(',')
945+
if ! wipe_environments.index(@environment)
945946
expected_response = %Q{I WANT TO WIPE #{@environment.upcase}}
946947
print %Q{
947948
*******************************************************************************

0 commit comments

Comments
 (0)