1. when i am running “docker build . -t result-app” from “/home/sudhanshu/example-voting-app/result” directory it is giving me below error
<
ERROR: failed to solve: process “/bin/sh -c apt-get update && apt-get install -y --no-install-recommends curl tini && rm -rf /var/lib/apt/lists/*” did not complete successfully: exit code: 127
2. Below are the already running containers for your reference.
<
[root@linuxVM result]# docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
b4f3385b8adf node:18-slim “docker-entrypoint.s…” About an hour ago Up About an hour inspiring_heisenberg
90633e2124fc worker-app “dotnet Worker.dll” 2 hours ago Up 2 hours stupefied_brattain
d331b8df1cc4 postgres:15-alpine “docker-entrypoint.s…” 2 hours ago Up 2 hours 5432/tcp db
a3c23580bae0 voting-app “gunicorn app:app -b…” 2 hours ago Up 2 hours 0.0.0.0:5000->80/tcp, :::5000->80/tcp stoic_matsumoto
c407a8938510 redis “docker-entrypoint.s…” 2 hours ago Up 2 hours 6379/tcp redis
[root@linuxVM result]
3. Below is the Docker file for result-app
<
FROM node:18-slim
add curl for healthcheck
RUN apt-get update &&
apt-get install -y --no-install-recommends curl tini &&
rm -rf /var/lib/apt/lists/*
WORKDIR /usr/local/app
have nodemon available for local dev use (file watching)
RUN npm install -g nodemon
COPY package*.json ./
RUN npm ci &&
npm cache clean --force &&
mv /usr/local/app/node_modules /node_modules
COPY . .
ENV PORT 80
EXPOSE 80
ENTRYPOINT [“/usr/bin/tini”, “–”]
CMD [“node”, “server.js”]