Hi everyone;
a Docker Image for GravCMS
I just pushed a docker image based on Alpine 3.7 built à la Linux Server way!,
which means nginx & php runs as a user in the container.
What you will get ?
You will have the last grav+admin and the nginx default configuration I found on the github of getgrav.
APCu & OPCache Status*
You could see if and how APCu and OPCache are used at : ./apc.php and ./opcache.php
<details>
<summary>click here to see the source of these files</summary>
- APC Status comes from the github of krakjoe
- OPCache Status comes from the github of rlerdorf
</details>
I recommend you to remove them in production,
<details>
<summary>which you could easily do by executing :</summary>
GRAVIMG=$(docker ps|grep jodumont/grav|cut -d' ' -f1)
docker exec $GRAVIMG rm /config/www/grav-admin/apc.php
docker exec $GRAVIMG rm /config/www/grav-admin/opcache.php
[spoiler]If you delete them, they won't come back.[/spoiler]
</details>
What is inside the magic box ?
<details>
<summary>Nothing fancy and it won't require a lot of maintenance and update.</summary>
The container is based on : php requirements of getGrav +
- logrotate for nginx and php-fpm
- apcu as cache system
- exif if you want to use the auto metadata option
- opcache because php cache is never enough
- tidy in case you want to minify css and js
- yaml to increase dramatically the performance
The nginx default config also come from github getgrav.
and point to /config/www/grav-admin
The 1st run
GravCMS will be installed in /config/www/grav-admin
./apc.php and ./opcache.php will be pulled from github.
</details>
Source
is on my github
So enjoy and don't hesitate to give me feedback or ask question
I'm sure we could make it better.
and o!... I forget;
have a great day!
Jonathan