So, i got this dockerfile:
`FROM node:20.11.0-alpine AS BUILD_IMAGE
WORKDIR /strapi
Resolve node_modules
COPY package.json package-lock.json* ./
RUN npm ci --production=true --frozen-lockfile
Copy all for build and release cache if package.json update
COPY . .
ENV NODE_ENV=production
RUN npm run build
#------------------------------------------------------------------------------------
Create new namespace for final Docker Image
FROM node:20.11.0-alpine
Only copy source code without system file
COPY --from=BUILD_IMAGE /strapi /strapi
WORKDIR /strapi
EXPOSE 1337
ENV NODE_ENV=production
ENV STRAPI_LOG_LEVEL=debug
CMD [“npm”, “start”]
`
and run it with:
docker run -e ENV_PATH=/Users/alfinamegasiwi/Documents/MANSEK/STRAP-I/strapi-platform/.env strapi
why my .env doesnt get loaded? it shows this error:
error: “Bucket name” is required!
Error: “Bucket name” is required!
or postgresql error
This topic has been created from a Discord post (1284485524463157380) to give it more visibility.
It will be on Read-Only mode here.
Join the conversation on Discord