Fixed #365: Added check to config rake file (GRN-66) (#376)

* Added check to config rake file

* Update configuration.rake
This commit is contained in:
farhatahmad 2019-02-22 15:11:01 -05:00 committed by Jesus Federico
parent 7429349d3b
commit 5521402ee7
1 changed files with 7 additions and 5 deletions

View File

@ -29,10 +29,12 @@ namespace :conf do
test_request("#{ENV['BIGBLUEBUTTON_ENDPOINT']}api/getMeetings?checksum=#{checksum}") test_request("#{ENV['BIGBLUEBUTTON_ENDPOINT']}api/getMeetings?checksum=#{checksum}")
passed passed
# Tests the checksum on the getMeetings api call if ENV['ALLOW_MAIL_NOTIFICATIONS'] == 'true'
print "Checking SMTP connection" # Tests the configuration of the SMTP Server
test_smtp print "Checking SMTP connection"
passed test_smtp
passed
end
end end
end end
@ -50,7 +52,7 @@ rescue => exc
failed("Error connecting to SMTP - #{exc}") failed("Error connecting to SMTP - #{exc}")
end end
# takes the full URL including the protocol # Takes the full URL including the protocol
def test_request(url) def test_request(url)
uri = URI(url) uri = URI(url)
res = Net::HTTP.get(uri) res = Net::HTTP.get(uri)