Skip to content

Commit

Permalink
Fixed marklogic-community#800: refuse to upgrade for ML 6 and older
Browse files Browse the repository at this point in the history
  • Loading branch information
grtjn committed Jun 12, 2017
1 parent 0c8ea68 commit 334b3ea
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions deploy/lib/upgrader.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ class Upgrader
def initialize(options)
@logger = options[:logger]
@app_type = options[:properties]["ml.app-type"]
@server_version = options[:properties]["ml.server-version"].to_i
@no_prompt = options[:no_prompt]
end

Expand Down Expand Up @@ -57,6 +58,10 @@ def upgrade(args)
fork = find_arg(['--fork']) || 'marklogic'
branch = find_arg(['--branch']) || 'master'

if @server_version < 7 && branch != "v1.7.0"
raise ExitException.new("Upgrades to branch #{branch} no longer supported for MarkLogic #{@server_version}, use 'v1.7.0' instead")
end

print "This command will attempt to upgrade to the latest Roxy files.\n"
print "Before running this command, you should have checked all your code\n"
print "into a source code repository, such as Git or Subversion. Doing so\n"
Expand Down

0 comments on commit 334b3ea

Please sign in to comment.