This repository has been archived by the owner on Dec 14, 2022. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #131 from remind101/docker
Get a working docker env
- Loading branch information
Showing
10 changed files
with
198 additions
and
154 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,14 @@ | ||
language: ruby | ||
cache: bundler | ||
rvm: | ||
- 2.5.1 | ||
before_script: "./bin/rake db:setup" | ||
script: "./bin/rake" | ||
- 2.5.1 | ||
before_script: | ||
- psql -c 'create database travis_ci_test;' -U postgres | ||
- ./bin/rake db:setup | ||
env: | ||
- DATABASE_URL=postgres://postgres:@localhost/travis_ci_test | ||
script: ./bin/rake | ||
notifications: | ||
email: false | ||
addons: | ||
postgresql: "9.2" # json data type was introduced in postgres 9.2. Travis default is 9.1 | ||
postgresql: "9.6" # json data type was introduced in postgres 9.2. Travis default is 9.1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
FROM ruby:2.5.1 | ||
RUN apt-get update && \ | ||
apt-get install -y build-essential openssl libssl-dev libpq-dev postgresql-client | ||
RUN gem install bundler | ||
|
||
RUN mkdir -p /home/app | ||
WORKDIR /home/app | ||
|
||
COPY Gemfile /home/app/ | ||
COPY Gemfile.lock /home/app/ | ||
RUN bundle install --jobs 4 --retry 3 | ||
|
||
COPY . /home/app | ||
|
||
CMD ["bundle", "exec", "rake"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.