I Want to dockerizing my strapi app but have some problem like this image
I Already set the url in ./config/admin.js
module.exports = ({ env }) => ({
auth: {
secret: env('ADMIN_JWT_SECRET', 'ac0b654fce47e425cab20649bb95a2fa'),
},
url:"http://localhost:8004/admin"
});
and my ./config/server.js
module.exports = ({ env }) => ({
host: env('HOST', '0.0.0.0'),
port: env.int('PORT', 1337),
app: {
keys: env.array('APP_KEYS'),
},
url:"http://localhost:8004/"
});
my docker-compose.yml
services:
app-staging:
build:
context: .
container_name: api-strapi-dev
env_file: .env
ports:
- "8004:1337"
networks:
- strapi
restart: always
networks:
strapi:
external: true
my Dockerfile
FROM node:14-alpine
LABEL maintainer="Rupadana <rupadanawayan@gmail.com>"
WORKDIR /usr/src/app
RUN chown node:node .
USER node
COPY ./ ./
RUN npm install
ENTRYPOINT [ "npm","run", "start" ]
my .dockerignore
.cache
.tmp
.vscode
node_modules
build