From 2127bc1d8c98443e9d3769f080b67424f4c57b12 Mon Sep 17 00:00:00 2001 From: Cold-Egg Date: Wed, 11 Mar 2020 11:05:54 -0400 Subject: [PATCH] readme update --- README.md | 26 +++++++++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 7e3213d..1b93a8e 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [](litespeedtech.com/slack) [](https://twitter.com/litespeedtech) -Install a lightweight WordPress container with OpenLiteSpeed Edge or Stable version on Ubuntu 18.04 Linux. +Install a lightweight WordPress container with OpenLiteSpeed Edge or Stable version based on Ubuntu 18.04 Linux. ### Prerequisites 1. [Install Docker](https://www.docker.com/) @@ -151,15 +151,35 @@ bash bin/webadmin.sh [-U, --upgrade] ### Apply OWASP ModSecurity Enable OWASP `mod_secure` on the web server: ``` -bash bin/webadmin.sh [-modsec|-sec] enable +bash bin/webadmin.sh [-M, --mod-secure] enable ``` Disable OWASP `mod_secure` on the web server: ``` -bash bin/webadmin.sh [-modsec|-sec] disable +bash bin/webadmin.sh [-M, --mod-secure] disable ``` + ### Accessing the Database After installation, you can use phpMyAdmin to access the database by visiting `http://127.0.0.1:8080` or `https://127.0.0.1:8443`. The default username is `root`, and the password is the same as the one you supplied in the `.env` file. +## Customization +If you want to customize the image by adding some packages, e.g. `lsphp74-pspell`, just extend it with a Dockerfile. +1. We can create a `custom` folder and a `custom/Dockerfile` file under the main project. +2. Add the following example code to `Dockerfile` under the custom folder +``` +FROM litespeedtech/openlitespeed:latest +RUN apt-get update && apt-get install lsphp74-pspell +``` +3. Add `build: ./custom` line under the "image: litespeedtech" of docker-composefile. So it will looks like this +``` + litespeed: + image: litespeedtech/openlitespeed:${OLS_VERSION}-${PHP_VERSION} + build: ./custom +``` +4. Build and start it with command: +``` +docker-compose up --build +``` + ## Support & Feedback If you still have a question after using OpenLiteSpeed Docker, you have a few options. * Join [the GoLiteSpeed Slack community](litespeedtech.com/slack) for real-time discussion