From 317e6e8cc591831a972b5ce18a33e58c155c3823 Mon Sep 17 00:00:00 2001 From: bruckwubete Date: Tue, 21 Aug 2018 15:55:50 -0400 Subject: [PATCH] update to add github trigger --- Jenkinsfile | 8 ++- app/controllers/application_controller.rb | 2 +- .../shared/components/_recording_row.html.erb | 2 +- config/initializers/version.rb | 2 +- spec/controllers/users_controller_spec.rb | 63 ++++++++++++------- 5 files changed, 51 insertions(+), 26 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 52a9c505..06f10674 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -11,6 +11,12 @@ if (env.TAG_NAME && env.TAG_NAME.contains("release")) { kubecSecretsId = 'gl-launcher-staging-secrets' } +properties([ + pipelineTriggers([ + githubPush() + ]) +]) + podTemplate(label: label, cloud: "${kubeCloud}", containers: [ containerTemplate(name: 'ruby', image: "ruby:2.5.1", command: 'cat', ttyEnabled: true), containerTemplate(name: 'gcloud', image: "gcr.io/ci-cd-for-bn/gcloud-docker", command: 'cat', ttyEnabled: true), @@ -31,7 +37,7 @@ volumes: [ stage('Test') { container('ruby') { - sh "bundle install && bundle exec rubocop && bundle exec rspec" + sh "bundle install --without development production && bundle exec rubocop && bundle exec rspec" } } diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index a35b39a6..2176cbfb 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -25,7 +25,7 @@ class ApplicationController < ActionController::Base before_action :set_locale # Force SSL for loadbalancer configurations. - before_filter :redirect_to_https + before_action :redirect_to_https protect_from_forgery with: :exception diff --git a/app/views/shared/components/_recording_row.html.erb b/app/views/shared/components/_recording_row.html.erb index c567d771..b1489b53 100644 --- a/app/views/shared/components/_recording_row.html.erb +++ b/app/views/shared/components/_recording_row.html.erb @@ -38,7 +38,7 @@
<%= t("recording.table.users") %>
- <%= recording[:participants] %> + <%= recording[:participants] || "-" %>