Git Product home page Git Product logo

Comments (2)

davesade avatar davesade commented on May 27, 2024 1

@ChristianHeimke Thanks for a response - and I understand and agree, this is issue only if used with strapi/strapi image. We did a switch to strapi/base already.

For future reference I'd like add my two cents:

Most of the documentation seems to be written in a way of running Strapi on standalone machine with one persistent volume (example). It is assumed, that one will SSH into the instance, make necessary changes, rebuild application and then run it.

Running Strapi in Docker, using recommended Dockerfiles, will result a fresh build on runtime, which is taking many minutes even on powerful instances and it's not designed to run in parallel with single volume on cluster. Upgrading application and it's plugins or configuration requires change on the volume and restarting containers, initiating rebuild. This approach might be fine for some cases.

Approach we took, as outlined above, is to have app folder in GIT and then running yarn build in Dockerfile. That will create Docker image with versioned configurations, no extra volume mount (we use an external bucket for media files) and that enables us to run Strapi in multiple replicas with very short boot time - making it more usable for cloud workloads.

It would be awesome to see those features being implemented in Strapi directly, plus staging of content between environments.

That's all from my side, have a great day!

from strapi-docker.

ChristianHeimke avatar ChristianHeimke commented on May 27, 2024

@davesade I totally agree with your thoughts. But as far as I understand the starpi-docker universe, the starpi/strapi image is only for development and testing purpose.

If you want to run strapi in a production env inside docker you should use the strapi/base image, as described in the readme:

When deploying a strapi application to production you can use docker to package your whole app in an image
(https://github.com/strapi/strapi-docker#how-to-use-strapibase)

I hope this will help for your production setup ;-)

from strapi-docker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.