File tree Expand file tree Collapse file tree 1 file changed +12
-14
lines changed Expand file tree Collapse file tree 1 file changed +12
-14
lines changed Original file line number Diff line number Diff line change 1
- FROM ruby:2.7.5 -alpine3.13
1
+ FROM ruby:3.0.4 -alpine3.15
2
2
3
3
MAINTAINER Andrew Kane <andrew@ankane.org>
4
4
5
- RUN apk add --update ruby-dev build-base \
6
- libxml2-dev libxslt-dev pcre-dev libffi-dev \
7
- postgresql-dev mysql-dev sqlite-dev git \
8
- unixodbc-dev freetds-dev
9
-
10
- RUN gem install bundler
11
-
12
- ENV INSTALL_PATH /app
5
+ ARG INSTALL_PATH=/app
6
+ ARG RAILS_ENV=production
7
+ ARG DATABASE_URL=postgresql://user:pass@127.0.0.1/dbname
8
+ ARG SECRET_TOKEN=dummytoken
13
9
14
10
RUN mkdir -p $INSTALL_PATH
15
11
16
12
WORKDIR $INSTALL_PATH
17
13
18
- COPY Gemfile Gemfile.lock ./
19
-
20
- RUN bundle install --binstubs
21
-
22
14
COPY . .
23
15
24
- RUN bundle exec rake RAILS_ENV=production DATABASE_URL=postgresql://user:pass@127.0.0.1/dbname SECRET_TOKEN=dummytoken assets:precompile
16
+ RUN apk add --update ruby-dev build-base libxml2-dev libxslt-dev pcre-dev libffi-dev libpq-dev mariadb-dev sqlite-dev git unixodbc-dev libpq mariadb-connector-c sqlite-libs unixodbc && \
17
+ gem install bundler && \
18
+ bundle install && \
19
+ bundle exec rails app:update:bin && \
20
+ bundle exec rake assets:precompile && \
21
+ apk del ruby-dev build-base libxml2-dev libxslt-dev pcre-dev libffi-dev libpq-dev mariadb-dev sqlite-dev git unixodbc-dev unixodbc-dev && \
22
+ rm -rf /var/cache/apk/*
25
23
26
24
ENV PORT 8080
27
25
You can’t perform that action at this time.
0 commit comments