Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pull Requiest Builder test #7

Open
wants to merge 16 commits into
base: master
Choose a base branch
from
19 changes: 19 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@

#FROM ruby:2.5.1
FROM ruby:2.3
RUN apt-get update -qq && apt-get install -y build-essential libpq-dev nodejs

# Install RMagick
# RUN apt-get install -y libmagickwand-dev imagemagick

# Install Nokogiri
# RUN apt-get install -y zlib1g-dev

RUN mkdir /myapp
WORKDIR /tmp
COPY Gemfile Gemfile
COPY Gemfile.lock Gemfile.lock
RUN bundle install -j 4

ADD . /myapp
WORKDIR /myapp
6 changes: 5 additions & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ gem 'rspec_junit_formatter', :require => false, :group => :test
gem 'simplecov', :require => false, :group => :test
git_source(:github) { |repo| "https://github.com/#{repo}.git" }

ruby '2.5.1'
#ruby '2.5.1'
ruby '2.3.8'

# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '~> 5.2.0'
Expand Down Expand Up @@ -36,6 +37,9 @@ gem 'jbuilder', '~> 2.5'
# Use Capistrano for deployment
# gem 'capistrano-rails', group: :development

# Use rubocop lint for code coverage report
gem 'rubocop', '~> 0.43.0'

# Reduces boot times through caching; required in config/boot.rb
gem 'bootsnap', '>= 1.1.0', require: false

Expand Down
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,7 @@ Things you may want to cover:
* Deployment instructions

* ...

GPullBuilder Test feature/branch1
GPullBuilder Test feature/branch2
GPullBuilder Test push event test1
13 changes: 13 additions & 0 deletions database.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
development: &default
adapter: postgresql
encoding: unicode
database: your-project_development
pool: 5
username: <%= ENV.fetch('DB_USERNAME', 'your-project') %>
password: <%= ENV.fetch('DB_PASSWORD', 'your-project') %>
host: <%= ENV.fetch('DB_1_PORT_5432_TCP_ADDR', 'localhost') %>
port: <%= ENV.fetch('DB_1_PORT_5432_TCP_PORT', '5432') %>

test: &test
<<: *default
database: your-project_test
32 changes: 32 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
db:
image: postgres
ports:
- "5432"

redis:
image: redis
ports:
- "6379"

web:
build: .
command: bundle exec rails s -p 3000 -b '0.0.0.0'
volumes:
- .:/myapp
ports:
- "3000:3000"
environment:
- DB_USERNAME=postgres
- DB_PASSWORD=
links:
- db
# - redis

# sidekiq:
# build: .
# command: bundle exec sidekiq
# links:
# - db
# - redis
# volumes:
# - .:/usr/src/service
2 changes: 1 addition & 1 deletion spec/spec_helper.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
require 'simplecov'
SimpleCov.start
require_relative '/var/lib/jenkins/workspace/CI_RubyOnRails/app/controllers/string_ops'
require_relative '../app/controllers/string_ops'