Hi,

When using a container, what is prudent to persist other than:

  1. The SQL database.
  2. The assets directory. (e.g. /var/www/html/public/assets/)
  3. Maybe the server logs.

Is /var/www/html/storage significant or ephemeral?

Is there anything else that might change outside of the above in day to day use of the Flarum site with regular user, admin, and mod activity?

Thank you!

  • luceos replied to this.
  • navindra Am I correct in assuming that the dynamically compiled PHP class will be created at runtime if it's missing?

    Yes. If you're going for a single instance, you can pretty much forget about everything except your current extension/package state (composer.* files) and the assets (public/assets), everything else isn't really important.

    navindra storage contains sessions and cache. Unless you move these elsewhere you will have an issue scaling.

    In addition storage also contains a formatter directory which contains a dynamically compiled PHP class that needs to be auto loadable using composer. You need to keep in mind when scaling that the files in that folder must exist on disk.

      luceos I'm only aiming to have a single instance but if I have to move it to another host or recreate it for any reason, it sounds like there is some benefit to keeping this directory?

      1. Users won't be logged out.
      2. Dynamically created code doesn't need to be recreated.

      So if the directory is missing for whatever reason, users will be forced to sign in again and the missing code has to be regenerated.

      Am I correct in assuming that the dynamically compiled PHP class will be created at runtime if it's missing?

      Thank you!

        navindra Am I correct in assuming that the dynamically compiled PHP class will be created at runtime if it's missing?

        Yes. If you're going for a single instance, you can pretty much forget about everything except your current extension/package state (composer.* files) and the assets (public/assets), everything else isn't really important.