File tree 4 files changed +336
-330
lines changed
4 files changed +336
-330
lines changed Original file line number Diff line number Diff line change
1
+ root = true
2
+
3
+ [* ]
4
+ end_of_line = lf
5
+ insert_final_newline = true
6
+
7
+ [* .{js,json,yml} ]
8
+ charset = utf-8
9
+ indent_style = space
10
+ indent_size = 2
Original file line number Diff line number Diff line change @@ -33,26 +33,28 @@ RUN case "$(dpkg --print-architecture)" in \
33
33
*) echo "Unsupported architecture" ; exit 1 ;; \
34
34
esac \
35
35
&& curl -fsSL https://nodejs.org/dist/v${NODE_VERSION}/node-v${NODE_VERSION}-linux-${ARCH}.tar.xz | tar -xJ -C /usr/local --strip-components=1 \
36
- && npm install -g yarn@$YARN_VERSION
36
+ && corepack enable \
37
+ && corepack prepare
[email protected] --activate
37
38
38
- # Verify Node.js and Yarn installation
39
- RUN yarn install --immutable
39
+ # Verify Yarn installation
40
+ RUN yarn --version
40
41
41
42
FROM nodejs AS build
42
43
44
+ # Copy package files first
45
+ COPY package.json yarn.lock .yarnrc.yml ./
46
+ COPY .yarn/releases/ ./.yarn/releases/
47
+
48
+ # Now run yarn install
49
+ RUN yarn install --immutable
50
+
43
51
# Install application gems
44
52
COPY Gemfile Gemfile.lock ./
45
53
RUN bundle config set --local build.nokogiri --use-system-libraries && \
46
54
bundle config build.msgpack --with-cflags="-O2" && \
47
55
bundle install --jobs 4 --retry 5 && \
48
56
rm -rf ~/.bundle/ "${BUNDLE_PATH}" /ruby/*/cache "${BUNDLE_PATH}" /ruby/*/bundler/gems/*/.git
49
57
50
- # Install node modules
51
- COPY .yarn/releases /.yarn/releases
52
- COPY .yarn/plugins /.yarn/plugins
53
- COPY package.json yarn.lock .yarnrc.yml ./
54
- RUN yarn install --frozen-lockfile
55
-
56
58
# Copy application code
57
59
COPY . .
58
60
You can’t perform that action at this time.
0 commit comments