This repository has been archived by the owner on Feb 22, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
For the "main" one, include the `Gemfile.lock` so builds don't get confused by newer library versions. For the "test" one, make it so that guard is its default action.
- Loading branch information
Showing
3 changed files
with
36 additions
and
33 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,16 +1,15 @@ | ||
FROM ruby:alpine | ||
MAINTAINER Darren Oakley <[email protected]> | ||
|
||
RUN apk add --no-cache ruby-dev build-base libxml2-dev libxslt-dev postgresql-dev mysql-dev openssl-dev | ||
RUN apk add --update --no-cache build-base ruby-dev libxml2-dev libxslt-dev postgresql-dev mysql-dev openssl-dev | ||
|
||
ENV APP_HOME /app | ||
|
||
RUN mkdir $APP_HOME | ||
WORKDIR $APP_HOME | ||
|
||
COPY Gemfile Gemfile | ||
|
||
RUN bundle install --jobs 4 --without test development | ||
COPY Gemfile.lock Gemfile.lock | ||
RUN bundle install --retry 10 --jobs 4 --without test | ||
|
||
COPY . . | ||
|
||
|
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 |
---|---|---|
@@ -1,30 +1,34 @@ | ||
app: | ||
build: . | ||
volumes: | ||
- .:/app | ||
command: 'bundle exec shotgun -p 5000 -o 0.0.0.0 -s puma' | ||
ports: | ||
- '5000:5000' | ||
environment: | ||
RACK_ENV: 'development' | ||
DATABASE_URL: 'postgres://bandiera:bandiera@db/bandiera' | ||
LOG_TO_STDOUT: 'true' | ||
links: | ||
- db | ||
version: '2' | ||
services: | ||
app: | ||
build: . | ||
volumes: | ||
- .:/app | ||
command: 'bundle exec shotgun -p 5000 -o 0.0.0.0 -s puma' | ||
ports: | ||
- '5000:5000' | ||
environment: | ||
RACK_ENV: 'development' | ||
DATABASE_URL: 'postgres://bandiera:bandiera@db/bandiera' | ||
LOG_TO_STDOUT: 'true' | ||
links: | ||
- db | ||
|
||
test: | ||
build: . | ||
volumes: | ||
- .:/app | ||
command: 'bundle exec guard -i -p -l 1' | ||
environment: | ||
RACK_ENV: 'test' | ||
LOG_TO_STDOUT: 'true' | ||
test: | ||
build: | ||
context: ./ | ||
dockerfile: Dockerfile.test | ||
volumes: | ||
- .:/app | ||
command: 'bundle exec guard -i -p -l 1' | ||
environment: | ||
RACK_ENV: 'test' | ||
LOG_TO_STDOUT: 'true' | ||
|
||
db: | ||
image: postgres | ||
ports: | ||
- '5432' | ||
environment: | ||
POSTGRES_USER: 'bandiera' | ||
POSTGRES_PASSWORD: 'bandiera' | ||
db: | ||
image: postgres | ||
ports: | ||
- '5432' | ||
environment: | ||
POSTGRES_USER: 'bandiera' | ||
POSTGRES_PASSWORD: 'bandiera' |