2017 © Pedro Peláez
 

project lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

image

khs1994/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  • Shell
  • 0 Dependents
  • 0 Suggesters
  • 21 Forks
  • 56 Open issues
  • 18 Versions
  • 0 % Grown

The README.md

LNMP Docker

GitHub stars GitHub release GitHub (pre-)release license Build Status, (*1)

star, (*2)

:computer: :whale: :elephant: :dolphin: :penguin: :rocket: Start LNMP In Less than 2 minutes Powered By Docker Compose, one command $ ./lnmp-docker up, (*3)

Platform Status
Windows Build status
Linux Build Status
macOS CI
Linux arm64v8 -

, (*4)

LNMP Docker is supported on Linux, macOS, Windows 10 on x86_64, and Debian (Raspberry Pi3) on arm., (*13)

:warning: Don't Edit Any Files except .env Why ?, (*14)

:warning: Run Laravel on Docker For Windows very slow. solve it., (*15)

:gift: Donate, (*16)

WeChat

, (*17)

Welcome developer subscribe WeChat, (*18)

Prerequisites

To use LNMP Docker, you need:, (*19)

:one: Git, (*20)

:two: Docker 23.11 Stable +, (*21)

:three: Docker Compose v2.17.0+, (*22)

:four: WSL (Windows Only), (*23)

Quick Start

Windows 10

Please see Windows 10., (*24)

Install

Use git install LNMP Docker., (*25)

$ git clone --depth=1 https://github.com/khs1994-docker/lnmp.git

# $ git clone --depth=1 git@github.com:khs1994-docker/lnmp.git

# 中国镜像

$ git clone --depth=1 https://gitee.com/khs1994-docker/lnmp.git

# $ git clone --depth=1 git@gitee.com:khs1994-docker/lnmp.git

Start LNMP Demo

$ cd lnmp

$ ./lnmp-docker up

$ curl 127.0.0.1

Welcome use khs1994-docker/lnmp v23.11 x86_64 With Pull Docker Image

development

:bulb: MySQL default root password mytest, (*26)

Start PHP Project

Create new folder to start PHP project(e.g, Laravel) in ./app/ folder, And edit nginx config file in ./config/nginx/yourfilename.conf., (*27)

# $ ./lnmp-docker new

$ ./lnmp-docker restart nginx

You can set APP_ROOT to change PHP project folder., (*28)

More information please see Docker PHP Best Practice https://github.com/khs1994-docker/php-demo, (*29)

How to connect Services

$redis = new \Redis();

- $redis->connect('127.0.0.1',6379);
+ $redis->connect('redis', 6379);

- $pdo = new \PDO('mysql:host=127.0.0.1;dbname=test;port=3306','root','mytest');
+ $pdo = new \PDO('mysql:host=mysql,dbname=test,port=3306', 'root', 'mytest');

Advanced

PHPer commands

  • lnmp-php, (*30)

  • lnmp-composer, (*31)

  • lnmp-phpunit, (*32)

  • lnmp-laravel, (*33)

  • ..., (*34)

For more information please see Documents, (*35)

Issue SSL certificate

Powered by acme.sh, (*36)

$ ./lnmp-docker ssl khs1994.com -d *.khs1994.com

Please set API key and id in .env file or System ENV. Support Self-Signed SSL certificate, for more information, see Documents., (*37)

List LNMP Container

$ docker container ls -a -f label=com.khs1994.lnmp

Use Self-Build Docker Image

Edit Dockerfile in ./dockerfile/*/Dockerfile, then exec ./lnmp-docker build., (*38)

Restart

# Restart all container
$ ./lnmp-docker restart

$ ./lnmp-docker restart nginx php8

Stop

$ ./lnmp-docker stop

Stop and remove

$ ./lnmp-docker down

Overview

Features

Please see Documents., (*39)

What's inside

Name Docker Image Version Based
ACME.sh khs1994/acme:3.0.0 3.0.0 alpine:3.16
NGINX nginx:1.25.3-alpine 1.25.3 alpine:3.13
NGINX Unit khs1994/php:8.3.0-unit-alpine 1.30.0 alpine:3.16
HTTPD httpd:2.4.53-alpine 2.4.53 alpine:3.16
MySQL mysql:8.0.33 8.0.33 oraclelinux:8-slim
MariaDB mariadb:10.11.5 10.11.5 ubuntu:jammy
Redis redis:7.0.0-alpine 7.0.0 alpine:3.16
PHP-FPM khs1994/php:8.3.0-fpm-alpine 8.3.0 alpine:3.19
Composer khs1994/php:8.3.0-composer-alpine 2.5.8 alpine:3.19
Memcached memcached:1.6.15-alpine 1.6.15 alpine:3.16
RabbitMQ rabbitmq:3.9.0-management-alpine 3.9.0 alpine:3.13
PostgreSQL postgres:14.0-alpine 14.0 alpine:3.14
MongoDB mongo:5.0.3 5.0.3 ubuntu:bionic
PHPMyAdmin phpmyadmin:5.2.0 5.2.0 alpine:3.16
Registry registry:latest latest alpine:3.11

Folder Structure

Folder description
app PHP project (HTML, PHP, etc)
scripts/backup backup database file
bin PHPer Commands
config configuration file
dockerfile Dockerfile
log log file
scripts bash shell script

Exposed Ports

  • 80
  • 443

CLI

Easy to generate nginx or apache config, etc. Please use ./lnmp-docker., (*40)

Who use in Production?

khs1994.com

PCIT -- PHP CI TOOLKIT

HTTP3/QUIC

Please see https://github.com/khs1994-docker/lnmp/issues/895, (*41)

CI/CD

Please see khs1994-docker/ci, (*42)

Documents

https://docs.lnmp.khs1994.com, (*43)

Contributing

Please see Contributing, (*44)

Thanks

More Information

Please see https://zan.khs1994.com, (*45)

The Versions

30/07 2018

dev-master

9999999-dev https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

26/07 2018

dev-renovate/docker-gitlab-gitlab-ce-latest

dev-renovate/docker-gitlab-gitlab-ce-latest https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

23/07 2018

dev-renovate/docker-alpine-3.7

dev-renovate/docker-alpine-3.7 https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

23/07 2018

dev-dev

dev-dev https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

11/07 2018

v18.08

18.08.0.0 https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

21/05 2018

v18.07

18.07.0.0 https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

01/05 2018

dev-renovate/docker-digests-pin

dev-renovate/docker-digests-pin https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

01/05 2018

dev-renovate/docker-debian-stretch-slim

dev-renovate/docker-debian-stretch-slim https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

28/04 2018

dev-renovate/docker-arm32v7-php-7.2.5-fpm-stretch

dev-renovate/docker-arm32v7-php-7.2.5-fpm-stretch https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

28/04 2018

v18.06

18.06.0.0 https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

09/04 2018

v18.06-rc1

18.06.0.0-RC1 https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

01/04 2018

v18.05

18.05.0.0 https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

01/04 2018

dev-renovate/pin-docker-digests

dev-renovate/pin-docker-digests https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

01/04 2018

dev-renovate/docker-alpine-3.x

dev-renovate/docker-alpine-3.x https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

01/04 2018

dev-renovate/configure

dev-renovate/configure https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

27/03 2018

dev-revert-316-dev

dev-revert-316-dev https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

26/03 2018

v18.05-rc2

18.05.0.0-RC2 https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd

17/03 2018

v18.05-rc1

18.05.0.0-RC1 https://github.com/khs1994-docker/lnmp

Start LNMP In less than 2 minutes Powered by Docker Compose.

  Sources   Download

MIT

The Requires

  • php >=5.6

 

docker cicd