11 Star 39 Fork 23

Pear Admin / Pear Admin Laravel

Create your Gitee Account
Explore and code with more than 8 million developers,Free private repositories !:)
Sign up
Clone or Download
contribute
Sync branch
Cancel
Notice: Creating folder will generate an empty file .keep, because not support in Git
Loading...
readme.md

版本

当前版本基于Laravel7.x构建

TODO

  • 更新上传功能,包括单文件上传,多文件上传,编辑器上传
  • 集成百度编辑器(UEditor)
  • 集成MarkDown编辑器(Editor.io)
  • 集成stock.io实时接收通知
  • 集成log-viewer可视化管理项目日志

安装

获取项目代码

cd web部署目录
git clone https://gitee.com/pear-admin/Pear-Admin-Laravel.git
chmod -R 755 ./Pear-Admin-Laravel
cd ./Pear-Admin-Laravel
composer update

创建数据库

mysql -uroot -p  #输入密码
create database pear_admin_laravel

配置数据库

cp .env.example .env #配置.env里的数据库连接信息

初始化数据

php artisan key:generate    #初始化key
php artisan storage:link    #软连文件存储目录
chmod -R 755 storage/       #文件存储目录权限
php artisan migrate --step  #执行数据迁移
php artisan db:seed         #写入初始化数据

初始化完成后浏览器打开项目地址 https://www.domain.com/admin 登录

初始化登录用户名:admin 密码:password

可视化日志管理路由 https://www.domain.com/log-viewer

务必在登录成功后修改密码

其他

Vhost-Apache配置

<VirtualHost *:80>
    DocumentRoot "/var/www/html/Pear-Admin-Laravel/public"
    ServerName www.domain.com
    ErrorLog "logs/site1-error.log"
    CustomLog "logs/site1-access.log" common
    <Directory "/var/www/html/HBAdmin/public">
        Options FollowSymLinks
        AllowOverride All
        Require all granted
    </Directory>
</VirtualHost>

Vhost-Nginx配置

server {
    listen       80;
    server_name  www.domain.com;
    root         /var/www/html/Pear-Admin-Laravel/public;
    index index.html index.htm index.php;

    add_header X-Frame-Options "SAMEORIGIN";
    add_header X-XSS-Protection "1; mode=block";
    add_header X-Content-Type-Options "nosniff";

    charset utf-8;

    location / {
        try_files $uri $uri/ /index.php?$query_string;
    }

    location = /favicon.ico { 
        access_log off; 
        log_not_found off; 
    }
    location = /robots.txt  { 
        access_log off; 
        log_not_found off; 
    }

    location ~ .php$ {
        try_files $uri =404;
        root /var/www/html/Pear-Admin-Laravel/public;
        fastcgi_pass 127.0.0.1:9000;
        fastcgi_index index.php;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        include fastcgi.conf;
    }
    
    error_page 404 /404.html;
    location = /40x.html {
    }
    error_page 500 502 503 504 /50x.html;
        location = /50x.html {
    }
}

redis安装

cd ~
wget https://download.redis.io/releases/redis-6.2.5.tar.gz
tar xzf redis-6.2.5.tar.gz 
cd redis-6.2.5
make
make install PREFIX=/usr/local/redis
cd /usr/local/redis/bin/
ll
cp ~/redis-6.2.5/redis.conf ./
vim redis.conf  #找到daemonize no 改为daemonize yes
./redis-server redis.conf  #后台启动redis
ps aux|grep redis  #查看redis进程

About

🍂 基 于 Pear Admin 与 Laravel 的 后 台 管 理 系 统 expand collapse
PHP and 6 more languages
MIT
Cancel

Releases (1)

All

Contributors

All

Activities

Load More
can not load any more
PHP
1
https://gitee.com/pear-admin/Pear-Admin-Laravel.git
git@gitee.com:pear-admin/Pear-Admin-Laravel.git
pear-admin
Pear-Admin-Laravel
Pear Admin Laravel
version7

Search

E71a60c3 8189591 Df7b7c6b 8189591