Skip to content

Commit 2ed1349

Browse files
authored
fix: Update Dockerfile-v27 add ulimit -c 0 (#322)
* Update Dockerfile-v27 add ulimit -c 0 * Update Dockerfile-v27
1 parent d5a4719 commit 2ed1349

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

ci-runner/Dockerfile-v27

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,17 @@ RUN apk update && apk add --no-cache --virtual .build-deps && apk add bash && ap
2424
apk --purge -v del py-pip && \
2525
rm /var/cache/apk/*
2626

27+
# Ensure /bin/sh reads /etc/shinit for interactive shells
28+
ENV ENV=/etc/shinit
29+
30+
# Disable core dumps for login shells, bash, and non-login /bin/sh
31+
RUN set -euo pipefail; \
32+
mkdir -p /etc/profile.d; \
33+
printf 'ulimit -c 0\n' > /etc/profile.d/disable-core.sh; \
34+
printf 'ulimit -c 0\n' > /etc/bash.bashrc; \
35+
printf 'ulimit -c 0\n' >> /root/.bashrc; \
36+
printf 'ulimit -c 0\n' > /etc/shinit
37+
2738
COPY --from=docker/compose:1.29.2 /usr/local/bin/docker-compose /usr/bin/docker-compose
2839

2940
COPY ./buildpack.json /git-ask-pass.sh /

0 commit comments

Comments
 (0)