You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
FROM --platform=arm64 oven/bun:canary
ENV NODE_ENV production
# Install Doppler CLIRUN apt-get update && apt-get install -y apt-transport-https ca-certificates curl gnupg && \
curl -sLf --retry 3 --tlsv1.2 --proto "=https"'https://packages.doppler.com/public/cli/gpg.DE2A7741A397C129.key' | gpg --dearmor -o /usr/share/keyrings/doppler-archive-keyring.gpg && \
echo "deb [signed-by=/usr/share/keyrings/doppler-archive-keyring.gpg] https://packages.doppler.com/public/cli/deb/debian any-version main" | tee /etc/apt/sources.list.d/doppler-cli.list && \
apt-get update && \
apt-get -y install doppler
RUN bun i -g typescript
WORKDIR /usr/src/app
COPY package.json .
COPY bun.lockb .
RUN bun install --frozen-lockfile
ADD . /usr/src/app
CMD ["bun", "--smol", "start:doppler"]
When I remove the doppler installation and replace the CMD line with
CMD ["bun", "src/index.ts"]
I get no error message and the container just dies.
What is the expected behavior?
I expect the container to run as it does locally.
I would also expect more descriptive error message when something goes wrong.
Bun is able to execute the files with bun src/index.ts outside the docker container just fine.
What do you see instead?
This is a screenshot of the logs of the container that just dies:
Additional information
The image built and ran just fine on a machine with the following OS:
Linux 5.15.0-83-generic x86_64 x86_64
Side Note on error messages
I had a config error earlier where the progream wasn't finding the redis instance, and I couldn't figure it out based on the bun error message. I had to run the program with node and got a more descriptive error message.
This isn't part of the issue but it would make debugging easier and allow to post more descriptive steps on how to reproduce this issue
Activity
ChandlerVS commentedon Dec 11, 2023
I am having this same issue.
bun src/index.tsruns just fine outside the container, but inside it exits with code 137.EDIT: The issue does not exist on debian based images. Only on alpine based images.