File tree Expand file tree Collapse file tree 12 files changed +55
-11
lines changed Expand file tree Collapse file tree 12 files changed +55
-11
lines changed Original file line number Diff line number Diff line change 1- # laravel-dockerized
2- Laravel Dockerized
1+ # Laravel Dockerized
2+ ![ GitHub release (latest by date including pre-releases)] ( https://img.shields.io/github/v/release/kodhub/laravel-dockerized?include_prereleases )
3+ ![ GitHub issues] ( https://img.shields.io/github/issues-raw/kodhub/laravel-dockerized )
4+ ![ GitHub closed issues] ( https://img.shields.io/github/issues-closed-raw/kodhub/laravel-dockerized?color=009fe1 )
5+ ![ GitHub All Releases] ( https://img.shields.io/github/downloads/kodhub/laravel-dockerized/total? )
6+
7+ Laravel easy docker environment.
8+
9+ ### Support
10+ * nginx
11+ * php-fpm ( v7.2 )
12+ * mysql ( v5.7 )
13+ * redis
14+ * crontab
15+ * supervisor
16+
17+ ### Install on Your Laravel Project
18+
19+ Write the following code to the directory where your project folder is located on the terminal.
20+
21+ 1- ` git clone git@github.com:kodhub/laravel-dockerized.git .docker `
22+
23+ 2- ` docker-compose up -d --build `
24+
25+ 3- ` docker exec -it <container-id> bash `
26+
27+ 4- Your project install steps
28+
29+
30+ ### Documentation
31+
32+ coming soon..
Original file line number Diff line number Diff line change 11## FIRST LINE NON DELETE!! ##
2- * * * * * ls -lah >> /tmp/crontab.log
3- * * * * * pwd >> /tmp/crontab-pwd.log
2+ * * * * * php /var/www/artisan schedule:run >> /var/log/schedule-run.log
Original file line number Diff line number Diff line change 22nodaemon=true
33
44[program:system-mysql]
5- command=mysqld_safe
5+ command=/usr/bin/pidproxy /var/run/mysqld/mysqld.pid /opt/docker/system/program/start-mysql.sh
6+ stop-command=
67autostart=true
78autorestart=true
89stdout_logfile=/var/log/mysql.log
Original file line number Diff line number Diff line change @@ -7,4 +7,7 @@ services:
77 - " ${MYSQL_PORT}:3306"
88 - " ${SUPERVISOR_PORT}:9001"
99 volumes :
10- - ../:/var/www
10+ - ../:/var/www
11+ - /root
12+ - /var/lib/mysql
13+ - /var/log
Original file line number Diff line number Diff line change 1- #! /bin/bash
1+ #! /usr/ bin/env bash
22echo " 3RD installer starting..."
33
44apt update && apt install -ym \
@@ -14,7 +14,7 @@ echo "3RD installer completed..."
1414
1515cat /etc/crontab/crontab.conf > /etc/cron.d/crontab.tpl
1616
17- while IFS=" " read -r p || [ -n " $p " ]
17+ while IFS=" " read -r p || [[ -n " $p " ] ]
1818do
1919 printf ' %s\n' " $p "
2020 (crontab -l && echo " $p " ) | crontab -
Original file line number Diff line number Diff line change 1+ #! /usr/bin/env bash
12echo " Mysql installer starting..."
23
34# Install mysql
@@ -17,6 +18,7 @@ echo "Mysql installer starting..."
1718service mysql start
1819
1920mysql -e " CREATE DATABASE laravel /*\!40100 DEFAULT CHARACTER SET utf8 */;"
20- mysql -e " CREATE USER root@% IDENTIFIED BY '';"
21- mysql -e " GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY '';"
21+ mysql -e " CREATE USER 'root'@'localhost' IDENTIFIED BY '';"
22+ mysql -e " GRANT ALL PRIVILEGES ON *.* TO 'root'@'localhost' IDENTIFIED BY '';"
23+ mysql -e " UPDATE mysql.user SET plugin = 'mysql_native_password' WHERE User='root';"
2224mysql -e " FLUSH PRIVILEGES;"
Original file line number Diff line number Diff line change 1+ #! /usr/bin/env bash
12echo " Nginx installer starting.."
23
3- apt install nginx -y
4+ apt install nginx -y
Original file line number Diff line number Diff line change 1+ #! /usr/bin/env bash
12echo " PHP-FPM installer starting..."
23
34export DEBIAN_FRONTEND=noninteractive
Original file line number Diff line number Diff line change 1+ #! /usr/bin/env bash
12echo " Mysql installer starting..."
23
34apt install redis-server php-redis -y -o Dpkg::Options::=" --force-confold"
You can’t perform that action at this time.
0 commit comments