https://github.com/gundamew/bsdock
Yet another dockerized PHP development environment.
https://github.com/gundamew/bsdock
docker docker-compose lemp local-development
Last synced: 7 months ago
JSON representation
Yet another dockerized PHP development environment.
- Host: GitHub
- URL: https://github.com/gundamew/bsdock
- Owner: gundamew
- License: mit
- Created: 2018-01-15T08:54:27.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-07-25T04:29:18.000Z (about 6 years ago)
- Last Synced: 2025-01-21T14:46:38.879Z (9 months ago)
- Topics: docker, docker-compose, lemp, local-development
- Language: Dockerfile
- Homepage:
- Size: 59.6 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# bsdock
Try to dockerized my PHP development environment. It only contains Nginx, PHP-FPM, and MySQL containers.
Inspired by [Laradock](https://github.com/laradock/laradock).
## Requirement
I run the containers on **macOS High Sierra (10.13.4)** and **Docker CE for Mac (18.03.1-ce-mac65)**.
The scripts may work on Ubuntu or any other OS, but I did not test on them.
It uses [mkcert](https://github.com/FiloSottile/mkcert) to create self-signed SSL certificates.
## Usage
### 1. Create workspace
```shell
$ mkdir workspace
```### 2. Clone the repository
```shell
$ cd workspace/
$ git clone git@github.com:gundamew/bsdock.git
```### 3. Create self-signed SSL certificates
```shell
# Create a new local CA first
$ mkcert -install# Create new certificates for local development URLs
$ mkcert example.test localhost 127.0.0.1 ::1# Create a strong Diffie-Hellman group
$ sudo openssl dhparam -out /path/to/dhparam.pem 4096
```### 4. Create & run containers
```shell
$ docker-compose up -d --build
```## File Structure
```shell
.
├── bsdock
│ ├── docker-compose.yml
│ ├── mysql
│ ├── nginx
│ └── php-fpm
├── data
│ └── mysql
├── logs
│ └── nginx
└── www
└── example
└── index.php
```* `data/` Database system files
* `www/` The web server document root