File tree Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -28,8 +28,8 @@ RUN bundle config set force_ruby_platform true
28
28
# Install application gems
29
29
COPY Gemfile Gemfile.lock ./
30
30
RUN bundle install && \
31
- rm -rf ~/.bundle/ "${BUNDLE_PATH}" /ruby/*/cache "${BUNDLE_PATH}" /ruby/*/bundler/gems/*/.git && \
32
- bundle exec bootsnap precompile --gemfile
31
+ rm -rf ~/.bundle/ "${BUNDLE_PATH}" /ruby/*/cache "${BUNDLE_PATH}" /ruby/*/bundler/gems/*/.git \
32
+ && bundle exec bootsnap precompile --gemfile
33
33
34
34
# Copy application code
35
35
COPY . .
@@ -45,8 +45,8 @@ RUN SECRET_KEY_BASE_DUMMY=1 ./bin/rails assets:precompile
45
45
FROM base
46
46
47
47
# Install packages needed for deployment
48
- RUN apt-get update -qq && \
49
- apt-get install --no-install-recommends -y curl libvips libpq-dev && \
48
+ RUN apt-get update -qq \
49
+ && apt-get install --no-install-recommends -y curl libvips libpq-dev \
50
50
&& apt-get clean \
51
51
&& rm -rf /var/lib/apt/lists/*
52
52
@@ -55,8 +55,8 @@ COPY --from=build /usr/local/bundle /usr/local/bundle
55
55
COPY --from=build /rails /rails
56
56
57
57
# Run and own only the runtime files as a non-root user for security
58
- RUN useradd rails --create-home --shell /bin/bash && \
59
- chown -R rails:rails db log storage tmp
58
+ RUN useradd rails --create-home --shell /bin/bash \
59
+ && chown -R rails:rails db log storage tmp
60
60
USER rails:rails
61
61
62
62
# Entrypoint prepares the database.
Original file line number Diff line number Diff line change @@ -13,6 +13,7 @@ services:
13
13
ports :
14
14
- mode : ingress
15
15
target : 3000
16
+ published : 3000
16
17
deploy :
17
18
resources :
18
19
reservations :
You can’t perform that action at this time.
0 commit comments