twbs-bootstrap
SUCCESS
2m 35s
History Source
SummaryIterations1Transcript4Dockerfile
01Iteration 1
WRITEWriteFile· step #1
0s
Dockerfile492 bytes written
text18 lines · 492 chars
FROM node:slim

# Create app directory
WORKDIR /app

# Install dependencies from lockfile to ensure exact versions
COPY package.json package-lock.json ./
RUN npm ci

# Copy the rest of the source code
COPY . .

# Build the project from source (dist assets)
RUN npm run dist

# Default command: keep container alive after build and show dist contents
CMD ["bash", "-lc", "echo 'Bootstrap dist built at /app/dist'; ls -la dist; echo 'Container idle. Press Ctrl+C to exit.'; tail -f /dev/null"]
WRITEWriteFile· step #2
0s
/.dockerignore61 chars
dockerignore9 lines · 61 chars
node_modules
dist
.env
.git
_git
site/dist
site/.astro
_site
WRITEWriteFile· step #3
0s
.dockerignore72 bytes written
dockerignore9 lines · 72 chars
node_modules
dist
site/dist
_site
.github
.git
npm-debug.log*
yarn.lock
VERIFYVerifyBuild· step #4
1m 25s
VerifyBuildaccepted
Concerns: The CMD uses bash -lc; ensure the base image node:slim includes bash; if bash is not installed, container startup may fail., Build relies on an existing package-lock.json for npm ci; if the lockfile is missing or out of date, the build will fail., If npm run dist fails during build, the image will end up without a dist directory; consider handling build failures gracefully.
Smoke [PASS]: test -d /app/dist && ls -la /app/dist
Smoke [PASS]: ls -la /app/dist | wc -l