update license

This commit is contained in:
Aung Myo
2018-03-05 13:53:25 +06:30
parent 4bb597cb9d
commit 2c1f599990
4 changed files with 10 additions and 20 deletions

View File

@@ -1,4 +1,5 @@
class InstallController < BaseController
skip_before_action :lookup_domain
skip_before_action :verify_authenticity_token
# before_action :check_license
@@ -34,6 +35,7 @@ class InstallController < BaseController
if response[:status]
redirect_to root_url, notice: response["message"]
else
byebug
redirect_to activate_path, notice: response["message"]
end
end

View File

@@ -1,5 +1,4 @@
class ActionController::Base
before_action :lookup_domain, :set_locale
private
@@ -21,11 +20,11 @@ class ActionController::Base
end
else
# check for license file
# if check_license
# current_license(ENV["SX_PROVISION_URL"])
# else
# redirect_to activate_path
# end
if check_license
current_license(ENV["SX_PROVISION_URL"])
else
redirect_to activate_path
end
end
end

View File

@@ -12,7 +12,7 @@
development:
secret_key_base: b61d85f8ed2a1a9e0eeece3443b3e8f838d002cc1d9f32115d8e93db920e2957adfedc57501d44741211538f3108b742cdeada87d5bfae796c53da1f90a3cd61
sx_provision_url: 192.168.1.125:3002/api #connect.smartsales.dev/api #connect.smartsales.asia/api #provision.zsai.ws/api
sx_provision_url: connect.smartsales.dev/api #connect.smartsales.dev/api #connect.smartsales.asia/api #provision.zsai.ws/api
server_mode: application
cipher_type: AES-256-CBC
sx_key: Wh@t1$C2L
@@ -24,7 +24,7 @@ test:
# instead read values from the environment.
production:
secret_key_base: c4bc81065013f9a3506d385bcbd49586c42e586488144b0de90c7da36867de9fa880f46b5c4f86f0ce9b7c783bb5a73bdb0e5605a47716567294390e726d3e22
sx_provision_url: connect.smartsales.asia/api #192.168.1.147:3002/api
sx_provision_url: connect.smartsales.dev/api #192.168.1.147:3002/api
server_mode: cloud
cipher_type: AES-256-CBC
sx_key: Wh@t1$C2L

View File

@@ -1,18 +1,7 @@
{
"data": [
{
"lookup": "chromis-1.zsai.ws",
"value": {
"key": "877eY5iPvpVzaYnIkc2FgIy0U85FtqpTpQGqoM/RCG0=\n",
"iv": "qSVQaKzOm3TYmRP3DhHdig==\n"
}
},
{
"lookup": "gw2a-13.zsai.dev",
"value": {
"key": "R0uRkGlvCD5DGaPV4SkhGlwaMR0ohYBBmNna+tpRXMc=\n",
"iv": "AP5iuLM36oJmnvLsWCo9+Q==\n"
}
}
]
}