diff --git a/.npmrc b/.npmrc new file mode 100644 index 0000000..97b895e --- /dev/null +++ b/.npmrc @@ -0,0 +1 @@ +ignore-scripts=true diff --git a/.yarnrc.yml b/.yarnrc.yml new file mode 100644 index 0000000..1e5671c --- /dev/null +++ b/.yarnrc.yml @@ -0,0 +1 @@ +enableScripts: false diff --git a/samples/kubernetes-sample-extension/.npmrc b/samples/kubernetes-sample-extension/.npmrc new file mode 100644 index 0000000..97b895e --- /dev/null +++ b/samples/kubernetes-sample-extension/.npmrc @@ -0,0 +1 @@ +ignore-scripts=true diff --git a/samples/kubernetes-sample-extension/Dockerfile b/samples/kubernetes-sample-extension/Dockerfile index 309b875..9c7efd6 100644 --- a/samples/kubernetes-sample-extension/Dockerfile +++ b/samples/kubernetes-sample-extension/Dockerfile @@ -5,6 +5,7 @@ WORKDIR /ui # cache packages in layer COPY ui/package.json /ui/package.json COPY ui/package-lock.json /ui/package-lock.json +COPY .npmrc . RUN --mount=type=cache,target=/usr/src/app/.npm \ npm set cache /usr/src/app/.npm && \ diff --git a/samples/minimal-backend/.yarnrc.yml b/samples/minimal-backend/.yarnrc.yml new file mode 100644 index 0000000..1e5671c --- /dev/null +++ b/samples/minimal-backend/.yarnrc.yml @@ -0,0 +1 @@ +enableScripts: false diff --git a/samples/minimal-backend/Dockerfile b/samples/minimal-backend/Dockerfile index 67ab8f2..6f673f2 100644 --- a/samples/minimal-backend/Dockerfile +++ b/samples/minimal-backend/Dockerfile @@ -3,6 +3,7 @@ WORKDIR /app/client # cache packages in layer COPY client/package.json /app/client/package.json COPY client/yarn.lock /app/client/yarn.lock +COPY .yarnrc.yml . ARG TARGETARCH RUN yarn config set cache-folder /usr/local/share/.cache/yarn-${TARGETARCH} RUN --mount=type=cache,target=/usr/local/share/.cache/yarn-${TARGETARCH} yarn diff --git a/samples/minimal-docker-cli/.yarnrc.yml b/samples/minimal-docker-cli/.yarnrc.yml new file mode 100644 index 0000000..1e5671c --- /dev/null +++ b/samples/minimal-docker-cli/.yarnrc.yml @@ -0,0 +1 @@ +enableScripts: false diff --git a/samples/minimal-docker-cli/Dockerfile b/samples/minimal-docker-cli/Dockerfile index 0857369..a59e883 100644 --- a/samples/minimal-docker-cli/Dockerfile +++ b/samples/minimal-docker-cli/Dockerfile @@ -3,6 +3,7 @@ WORKDIR /app/client # cache packages in layer COPY client/package.json /app/client/package.json COPY client/yarn.lock /app/client/yarn.lock +COPY .yarnrc.yml . ARG TARGETARCH RUN yarn config set cache-folder /usr/local/share/.cache/yarn-${TARGETARCH} RUN --mount=type=cache,target=/usr/local/share/.cache/yarn-${TARGETARCH} yarn diff --git a/samples/oauth-sample/.npmrc b/samples/oauth-sample/.npmrc new file mode 100644 index 0000000..97b895e --- /dev/null +++ b/samples/oauth-sample/.npmrc @@ -0,0 +1 @@ +ignore-scripts=true diff --git a/samples/oauth-sample/Dockerfile b/samples/oauth-sample/Dockerfile index f216465..9099d3b 100644 --- a/samples/oauth-sample/Dockerfile +++ b/samples/oauth-sample/Dockerfile @@ -3,6 +3,7 @@ WORKDIR /ui # cache packages in layer COPY ui/package.json /ui/package.json COPY ui/package-lock.json /ui/package-lock.json +COPY .npmrc . RUN --mount=type=cache,target=/usr/src/app/.npm \ npm set cache /usr/src/app/.npm && \ npm ci diff --git a/samples/react/.yarnrc.yml b/samples/react/.yarnrc.yml new file mode 100644 index 0000000..1e5671c --- /dev/null +++ b/samples/react/.yarnrc.yml @@ -0,0 +1 @@ +enableScripts: false diff --git a/samples/react/Dockerfile b/samples/react/Dockerfile index fa98757..f709c35 100644 --- a/samples/react/Dockerfile +++ b/samples/react/Dockerfile @@ -3,6 +3,7 @@ WORKDIR /app/client # cache packages in layer COPY client/package.json /app/client/package.json COPY client/yarn.lock /app/client/yarn.lock +COPY .yarnrc.yml . ARG TARGETARCH RUN yarn config set cache-folder /usr/local/share/.cache/yarn-${TARGETARCH} RUN --mount=type=cache,target=/usr/local/share/.cache/yarn-${TARGETARCH} yarn