From 2e1405e1dd4042337e04e54208ca8db9b681625e Mon Sep 17 00:00:00 2001 From: Cold-Egg Date: Tue, 28 Jan 2020 15:19:16 -0500 Subject: [PATCH] update travis --- .travis.yml | 4 +--- .travis/main.sh | 0 .travis/verify.sh | 59 +++++++++++++++++++++++++++++++++++++++++++++++ README.md | 3 ++- 4 files changed, 62 insertions(+), 4 deletions(-) mode change 100644 => 100755 .travis/main.sh create mode 100755 .travis/verify.sh diff --git a/.travis.yml b/.travis.yml index 92e4806..f49d116 100644 --- a/.travis.yml +++ b/.travis.yml @@ -22,7 +22,6 @@ env: - DOCKER_COMPOSE_VERSION=1.25.0 before_install: - - chmod +x ./.travis/main.sh - ./.travis/main.sh install: @@ -36,8 +35,7 @@ before_script: - sleep 10 script: - - curl -Ik http://localhost:80/ - - curl -Ik http://localhost:443/ + - ./.travis/verify.sh after_success: - echo "${DOCKER_PASSWORD}" | docker login -u "${DOCKER_USERNAME}" --password-stdin diff --git a/.travis/main.sh b/.travis/main.sh old mode 100644 new mode 100755 diff --git a/.travis/verify.sh b/.travis/verify.sh new file mode 100755 index 0000000..c528b06 --- /dev/null +++ b/.travis/verify.sh @@ -0,0 +1,59 @@ +#!/bin/bash + +set -o errexit + +install_demo(){ + ./bin/demosite.sh +} + +verify_lsws(){ + curl -sIk http://localhost:7080/ | grep -i LiteSpeed + if [ ${?} = 0 ]; then + echo '[O] https://localhost:7080/' + else + echo '[X] https://localhost:7080/' + exit 1 + fi +} + +verify_page(){ + curl -sIk http://localhost:80/ | grep -i WordPress + if [ ${?} = 0 ]; then + echo '[O] http://localhost:80/' + else + echo '[X] http://localhost:80/' + exit 1 + fi + curl -sIk https://localhost:443/ | grep -i WordPress + if [ ${?} = 0 ]; then + echo '[O] https://localhost:443/' + else + echo '[X] https://localhost:443/' + exit 1 + fi +} + +verify_phpadmin(){ + curl -sIk http://localhost:8080/ | grep -i phpMyAdmin + if [ ${?} = 0 ]; then + echo '[O] http://localhost:8080/' + else + echo '[X] http://localhost:8080/' + exit 1 + fi + curl -sIk https://localhost:8443/ | grep -i phpMyAdmin + if [ ${?} = 0 ]; then + echo '[O] http://localhost:8443/' + else + echo '[X] http://localhost:8443/' + exit 1 + fi +} + +main(){ + verify_lsws + verify_phpadmin + install_demo + verify_page +} +main \ No newline at end of file diff --git a/README.md b/README.md index c1607b8..18aeddd 100644 --- a/README.md +++ b/README.md @@ -35,6 +35,7 @@ The docker image installs the following packages on your system: |LiteSpeed Cache|[Latest from WordPress.org](https://wordpress.org/plugins/litespeed-cache/)| |Certbot|[Latest from Certbot's PPA](https://launchpad.net/~certbot/+archive/ubuntu/certbot)| |WordPress|[Latest from WordPress](https://wordpress.org/download/)| +|phpMyAdmin|[Latest from dockerhub](https://hub.docker.com/r/bitnami/phpmyadmin/)| ## Data Structure There is a `sites` directory next to your `docker-compose.yml` file, and it contains the following: @@ -117,7 +118,7 @@ bash bin/webadmin.sh -lsup ``` ### Accessing the Database -After installation, you can use Adminer (formerly phpMinAdmin) to access the database by visiting http://127.0.0.1:8080. The default username is `root`, and the password is the same as the one you supplied in the `.env` file. +After installation, you can use phpMinAdmin 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. ## Support & Feedback If you still have a question after using OpenLiteSpeed Docker, you have a few options.