Software Engineer @Luno 馃殌 JS/TS and Docker enthusiast
Nothing here yet.
So in very simple terms. It's because it minimized attack surface of a container. Think of it in this scenario. node_modules where your web browser / server is running it can be exploited. Meaning I can get access to the container and I can go up the chain. If it's OUTSIDE, I get fewer exploits and have to go up further again.
Not to sure, i think that will depend on the project. I updated the guide kalle but didn't have any issues deploying it after that. I been working on a tool to help with heroku deployment to at least help with some of the issues people have. If you want to hit me up on Strapi Discord in a DM Feel free to and we can look into it. Normally if you get that error it seems it's a server error and it's not running as smooth as you want.
Hello Rich Bernhardt 馃憢 So I have many times, it really depends how you setup the project. If you are ONLY using the Dockerfile and not docker compose, you will need to change the .env and also expose the correct port in Dockerfile under EXPOSE. IF you are using docker-compose you still need to PASS port into as a variable, as I don't think the file is doing it ... environment: PORT: ${PORT} port: - "${PORT}:${PORT}" Else docker-compose won't have access to the environmental variable etc. In docker-compose I also normally then just do port: - "${PORT}:1337" That way I can control it what the OUT port is and not what strapi uses by default I just proxy it to my own port.
To add a answer Ezequiel Lamonica and kalle heroku config: set APP_KEYS=$(openssl rand -hex 64) -a awesomestrapi heroku config: set API_TOKEN_SALT=$(openssl rand -hex 32) -a awesomestrapi heroku config: set ADMIN_JWT_SECRET=$(openssl rand -hex 32) -a awesomestrapi heroku config: set JWT_SECRET=$(openssl rand -hex 32) -a awesomestrapi This will generate APP_KEYS, API_TOKEN_SALT, ADMIN_JWT_SECRET, JWT_SECRET all needed to make strapi run If you are running on the latest Strapi you need to generate more token keys to sort out what it was. Will update the thread with this.