Skip to content

Commit 3d25bc4

Browse files
committed
Changed README
1 parent bf35478 commit 3d25bc4

File tree

1 file changed

+20
-11
lines changed

1 file changed

+20
-11
lines changed

README.md

Lines changed: 20 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,17 @@
11
### Introduction
22
Docker environment configuration for Laravel development.
3-
Includes local end production settings.
3+
Contains settings for local development for new project or already existing.
44
>Repository provides:
55
> - Laravel 6
66
> - PHP 7.4
77
> - Nginx: 1.14
88
> - MySql 8.0
99
> - Redis
1010
> - Node latest
11+
> - LetsEncrypt for production
1112
1213
### Installation
13-
**Note:** Local environment tested only on Ubuntu. Feel free create an Issue for other OS.
14+
**Note:** Local environment tested only on Ubuntu. Feel free to create an Issue for other OS.
1415
1. **Clone repository**
1516
````
1617
mkdir {YOUR_NEW_FOLDER}
@@ -34,9 +35,6 @@ Includes local end production settings.
3435
````
3536
# Local development
3637
cp docker-compose.yml.local docker-compose.yml
37-
38-
# Production
39-
cp docker-compose.yml.prod docker-compose.yml
4038
````
4139
Set variables for mysql container. Docker will create database and user at first UP.
4240
````
@@ -59,8 +57,9 @@ Includes local end production settings.
5957
````
6058
5. **Run Application**
6159
````
60+
# Run containers
6261
docker-compose up -d --build
63-
docker-compose exec -uwww-data php-fpm composer install
62+
6463
docker-compose exec php-fpm php artisan key:generate
6564
# Base UI
6665
docker-compose exec -uwww-data php-fpm composer require laravel/ui --dev
@@ -71,17 +70,27 @@ Includes local end production settings.
7170

7271
# Migrate
7372
docker-compose exec -uwww-data php-fpm php artisan migrate
73+
74+
docker-compose exec -uwww-data php-fpm composer install
7475
````
7576
6. **Launch http://localhost:8989/register**
7677
77-
### LetsEncrypt and Production
78-
If you are going to use LetsEncrypt at production look at branch 'letsencrypt' this repository.
78+
### Production and LetsEncrypt
79+
Repository do not show full flow how to deploy docker application with build and docker registry,
80+
it can be used with simple git pull from your repository.
81+
For production without https you can use `develop` branch and production files.
82+
````
83+
# Production
84+
cp docker-compose.yml.prod docker-compose.yml #this compose file use nginx production config
85+
````
86+
If you are going to use LetsEncrypt at production look at branch 'letsencrypt' this repository.
7987
Branch contains ready to use configuration for letsEncrypt in production based on great article [Nginx and Let’s Encrypt with Docker in Less Than 5 Minutes](https://medium.com/@pentacent/nginx-and-lets-encrypt-with-docker-in-less-than-5-minutes-b4b8a60d3a71).
88+
8089
To use letsEncrypt at production just follow steps below:
81-
2. Initial settings
90+
1. Initial settings
8291
Open ``./init-letsencrypt.sh`` add your domains instead `{YOUR_DOMAIN}` www.`{YOUR_DOMAIN}` and set `{YOUR_EMAIL}`.
8392
Run ``./init-letsencrypt.sh``. It will create initial settings.
8493
Note: don't forget to add A DNS record for domain with www.
85-
3. Nginx settings
94+
2. Nginx settings
8695
At `.provision/nginx/conf.d/vhost.prod.conf` set `{YOUR_DOMAIN}` variable.
87-
96+
Certificates stored at .provision folder and will be renew as described in article.

0 commit comments

Comments
 (0)