Commit 8f394e8c authored by Cool Fire's avatar Cool Fire

Merge branch 'development' into 'master'

Preview 006

See merge request !11
parents 94a3d8bc 49e77406
Pipeline #381 passed with stages
in 4 minutes and 15 seconds
......@@ -40,7 +40,7 @@ lint_yaml:
script:
- gem install yamllint --no-ri --no-rdoc
- yamllint content/*.yaml
rack_test:
rack_test_2-4:
stage: testing
image: ruby:2.4-alpine
script:
......@@ -48,6 +48,14 @@ rack_test:
- bundle install
- touch .current
- ruby test.rb
rack_test_2-3:
stage: testing
image: ruby:2.3-alpine
script:
- gem install simplecov rack-test --no-ri --no-rdoc
- bundle install
- touch .current
- ruby test.rb
deploy_to_production:
stage: deploy
image: ubuntu:16.04
......@@ -58,7 +66,7 @@ deploy_to_production:
url: https://signup.insomnia247.nl
script:
- apt-get update
- apt-get install -y -qq ruby
- apt-get install -y -qq ruby curl
- 'which ssh-agent || (apt-get install -y -qq openssh-client)'
- eval $(ssh-agent -s)
- ssh-add <(echo "$SSH_PRIVATE_KEY")
......@@ -69,3 +77,4 @@ deploy_to_production:
- bash deployment/set_git_tag.sh
- bash deployment/populate_config.sh
- bash deployment/restart_application.sh
- curl -XPOST nanoapi.insomnia247.nl/v1/message -d "key=$NANOBOT_API_KEY&dest=#shells@&message=Deployed new version of signup-site to production."
......@@ -50,7 +50,7 @@ class SignupSite < Sinatra::Base
number.gsub!(/^(00|\+)/, '')
# Check for stray characters
return false if number.match?(/^\d+$/)
return false unless number.match(/^\d+$/).nil?
# Check with messagebird HLR if the phone number is valid
# TODO: Actually implement HLR lookup.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment