How to update wordpress on docker

后端 未结 5 547
再見小時候
再見小時候 2021-02-06 07:36

I\'m running a php-fpm wordpress container.

The wordpress source files are mounted in a named volume "wordpress" shared with the Nginx container.

Everyth

5条回答
  •  野的像风
    2021-02-06 08:18

    When the wordpress container comes up it checks for the existence of files at /var/www/html and copies only if not present. So in your case may you can update the entrypoint script to check the wordpress version in the wp-includes/version.php in the /var/www/html and the files in the container and then make a decision to replace the new files.

    Edit:

    According to this just deletion of index.php or wp-includes/version.php should copy the files from container again. Or may you can update your entrypoint script to copy files to /var/www/html all the time, but that may cause issues if you choose to scale the wordpress layer.

提交回复
热议问题