Uninote
Uninote

大爱金孝基础环境部署文档

1 心跳包长久ssh登录

vim /etc/ssh/sshd_config

# 客户端每隔多少秒向服务发送一个心跳数据
ClientAliveInterval 30
# 客户端多少秒没有相应,服务器自动断掉连接
ClientAliveCountMax 1800

service sshd restart

2 创建文件夹

mkdir Download
cd Download

3 安装lnmp集成环境

wget http://soft.vpser.net/lnmp/lnmp1.6.tar.gz -cO lnmp1.6.tar.gz && tar zxf lnmp1.6.tar.gz && cd lnmp1.6 && ./install.sh lnmp
  • nginx/1.16.1
  • PHP 7.2.24 (cli) (built: Dec 16 2019 18:58:20) ( NTS )
  • 5.6.44, for Linux (x86_64) using EditLine wrapper

4 建立软连接方便快捷使用

ln -s /usr/local/nginx/conf/ conf
ln -s /home/www www
ln -s /home/wwwlogs/ logs

5 安装PHP扩展

redis SeasLog php-redis php-seaslog redismyadmin

5.1 下载redis服务和安装

wget http://download.redis.io/releases/redis-5.0.0.tar.gz
tar -xzf redis-5.0.0.tar.gz
cd redis-5.0.0
make

5.2 开启redis服务

/root/Download/redis-5.0.0/src/redis-server &

5.3 下载PHP-redis扩展和安装

wget https://pecl.php.net/get/redis-4.1.1.tgz
tar xzf redis-4.1.1.tgz
cd redis-4.1.1
phpize
./configure --with-php-config=/usr/local/php/bin/php-config
make
make install
vim /usr/local/php/conf.d/ext-redis.ini
[redis]
extension=redis.so

5.4 修改php.ini配置

vim /usr/local/php/etc/php.ini

大约第1337行改为redis

session.save_handler = redis

第1352行添加一行

session.save_path = "tcp://127.0.0.1:6379"

解除禁用函数,第314行

disable_functions =

修改cgi.fix_pathinfo值为1,第776行

cgi.fix_pathinfo = 1

修改大约第477行

display_errors = On

5.5 下载redismyadmin到服务目录

wget https://github.com/daivem/RedisMyAdmin/archive/master.zip
mv master.zip RedisMyAdmin.zip
unzip RedisMyAdmin.zip
mv RedisMyAdmin-master/ /home/wwwroot/default/redismyadmin

修改index.html目录文件

vim /home/wwwroot/default/index.html

第32行修改为:

<p>查看本地环境: <a href="/p.php" target="_blank" class="links">探针</a>  <a href="/phpinfo.php" target="_blank" class="links">phpinfo</a>  <a href="/redismyadmin/" target="_blank" class="links">redisMyAdmin</a>  <a href="/phpmyadmin/" target="_blank" class="links">phpMyAdmin</a>(为了安全,建议将phpmyadmin目录重命名为不容易猜到的目录!)</p>

5.6 下载PHP-seaslog扩展和安装

wget https://pecl.php.net/get/SeasLog-1.8.6.tgz
tar xzf SeasLog-1.8.6.tgz
cd SeasLog-1.8.6
phpize
./configure --with-php-config=/usr/local/php/bin/php-config
make
make install
vim /usr/local/php/conf.d/ext-seaslog.ini
[SeasLog]
; configuration for php SeasLog module
extension = seaslog.so
; 默认log根目录
seaslog.default_basepath = "/tmp/log/seaslog-test"
; 默认logger目录
seaslog.default_logger = "default"
; 日期格式配置 默认"Y-m-d H:i:s"
seaslog.default_datetime_format = "Y-m-d H:i:s"
; 日志格式模板 默认"%T | %L | %P | %Q | %t | %M"
;seaslog.default_template = "%T -||- %L -||- %R -||- %C -||- %F -||- %Q -||- %M"
seaslog.default_template = "%t -||- %L -||- %C -||- %F -||- %Q -||- %M"
; 是否以目录区分Logger 1是(默认) 0否
seaslog.disting_folder = 1
; 是否以type分文件 1是 0否(默认)
seaslog.disting_type = 0
; 是否每小时划分一个文件 1是 0否(默认)
seaslog.disting_by_hour = 0
; 是否启用buffer 1是 0否(默认)
seaslog.use_buffer = 1
; buffer中缓冲数量 默认0(不使用buffer_size)
seaslog.buffer_size = 100
; cli运行时关闭buffer
; 1是 0否(默认)
seaslog.buffer_disabled_in_cli = 0
; 记录日志级别,数字越大,根据级别记的日志越多。
; 0-EMERGENCY 1-ALERT 2-CRITICAL 3-ERROR 4-WARNING 5-NOTICE 6-INFO 7-DEBUG 8-ALL
; 默认8(所有日志)
;
; 注意, 该配置项自1.7.0版本开始有变动。
; 在1.7.0版本之前, 该值数字越小,根据级别记的日志越多:
; 0-all 1-debug 2-info 3-notice 4-warning 5-error 6-critical 7-alert 8-emergency
; 1.7.0 之前的版本,该值默认为0(所有日志);
seaslog.level = 8
; 日志函数调用回溯层级
; 影响预定义变量 %F 中的行数
; 默认0
seaslog.recall_depth = 1
; 自动记录notice 默认0(关闭)
seaslog.trace_notice = 0
; 自动记录warning 默认0(开启)
seaslog.trace_warning = 0
; 自动记录错误 默认1(开启)
seaslog.trace_error = 0
; 自动记录异常信息 默认0(关闭)
seaslog.trace_exception = 0
; 日志存储介质 1File 2TCP 3UDP (默认为1)
seaslog.appender = 1
; 写入重试次数
; 默认0(不重试)
seaslog.appender_retry = 0
; 接收ip 默认127.0.0.1 (当使用TCP或UDP时必填)
seaslog.remote_host = "127.0.0.1"
; 接收端口 默认514 (当使用TCP或UDP时必填)
seaslog.remote_port = 514
; 接收端口的超时时间 默认1秒
seaslog.remote_timeout = 1
; 过滤日志中的回车和换行符 (默认为0)
seaslog.trim_wrap = 0
; 是否开启抛出SeasLog自身异常  1开启(默认) 0否
seaslog.throw_exception = 1
; 是否开启忽略SeasLog自身warning  1开启(默认) 0否
seaslog.ignore_warning = 1

6 设置ssh密钥

ssh-keygen -t rsa -b 4096 -C "your_email@example.com"

然后复制./.ssh/id_rsa.pub到仓库里的ssh里去。

7 克隆项目

  • 大爱金孝-后台管理中心
git clone git@git.xunwunet.com:eson/biglove-cms.git
  • 大爱金孝-员工端API
git clone git@git.xunwunet.com:eson/dajx-staff-api.git
  • 大爱金孝-客户端API
git clone git@git.xunwunet.com:caikang/dajx-api.git
  • 权限设置
chown -R www:www /home/www

8 设置mysql数据表

  • /home/www/biglove-cms/sql/biglove-cms.sql
  • /home/www/biglove-cms/sql/api-database.sql
  • /home/www/biglove-cms/sql/test.sql

9 设置域名https证书

  • 关闭lnmp服务
  • 获取脚本
wget https://dl.eff.org/certbot-auto
chmod a+x certbot-auto
  • 生成证书
./certbot-auto certonly --standalone -d staffapi.dajxyl.com -d
./certbot-auto certonly --standalone -d admin.dajxyl.com -d
./certbot-auto certonly --standalone -d api.dajxyl.com -d

10 设置nginx服务配置

10.1 服务器屏蔽nginx.confserver字段

第60行到101行,行首添加#注解掉server字段

vim /usr/local/nginx/conf/nginx.conf

10.2 修改fastcgi.conf配置

vim /usr/local/nginx/conf/fastcgi.conf

屏蔽第27行

# fastcgi_param PHP_ADMIN_VALUE "open_basedir=$document_root/:/tmp/:/proc/";

10.3 api.dajxyl.com

server{
    listen 443 ssl;
    server_name api.dajxyl.com;

    # ssl on;
    ssl_certificate             /etc/letsencrypt/live/api.dajxyl.com/fullchain.pem;
    ssl_certificate_key         /etc/letsencrypt/live/api.dajxyl.com/privkey.pem;

    include enable-php.conf;
    fastcgi_param PHP_ADMIN_VALUE "open_basedir=/home/www/:/tmp/:/proc/";

    root /home/www/dajx-api/web;
    index   index.html index.php;

    access_log  /home/wwwlogs/dajx-api.access.log;
    error_log   /home/wwwlogs/dajx-api.error.log;

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

10.4 staffapi.dajxyl.com

server{
    listen 443 ssl;
    server_name staffapi.dajxyl.com;

    # ssl on;
    ssl_certificate             /etc/letsencrypt/live/staffapi.dajxyl.com-0001/fullchain.pem;
    ssl_certificate_key         /etc/letsencrypt/live/staffapi.dajxyl.com-0001/privkey.pem;

    include enable-php.conf;
    fastcgi_param PHP_ADMIN_VALUE "open_basedir=/home/www/:/tmp/:/proc/";

    root /home/www/dajx-staff-api/web;
    index   index.html index.php;

    access_log  /home/wwwlogs/dajx-staff-api.access.log;
    error_log   /home/wwwlogs/dajx-staff-api.error.log;

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

10.5 admin.dajxyl.com

server {
    listen 443 ssl;
    server_name admin.dajxyl.com;

    # ssl on;
    ssl_certificate             /etc/letsencrypt/live/admin.dajxyl.com/fullchain.pem;
    ssl_certificate_key         /etc/letsencrypt/live/admin.dajxyl.com/privkey.pem;

    access_log  /home/wwwlogs/biglove_access.log;
    error_log   /home/wwwlogs/biglove_error.log;
    set         $root   /home/www/biglove-cms/cms/public;
    location ~ .*\.(gif|jpg|jpeg|bmp|png|ico|txt|js|css)$
    {
        root $root;
    }
    location / {
        root    $root;
        index   index.html index.php;
        if ( -f $request_filename) {
            break;
        }
        if ( !-e $request_filename) {
            rewrite ^(.*)$ /index.php/$1 last;
            break;
        }
    }
    location ~ .+\.php($|/) {
        fastcgi_pass    unix:/tmp/php-cgi.sock;
        # fastcgi_split_path_info ^((?U).+.php)(/?.+)$;
        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        fastcgi_param   PATH_INFO          $fastcgi_path_info;
        fastcgi_param   PATH_TRANSLATED    $document_root$fastcgi_path_info;
        fastcgi_param   SCRIPT_FILENAME    $root$fastcgi_script_name;
        include         fastcgi_params;
    }
}

11 设置项目的附属参数配置文件

11.1 /home/www/biglove-cms/cms/.env

[app]
debug = true
trace = false

[database]
hostname = localhost
database = 'biglove'
username = root
password = 'root123.'
hostport = 3306
prefix =

[database-api]
hostname-api = localhost
database-api = 'dajx-api'
username-api = root
password-api = 'root123.'
hostport-api = 3306
prefix-api =

11.2 /home/www/biglove-cms/cms/config/__params.php

<?php

return [
    'IGt_app' => [
        // IGt 推送配置
        /**
         * @online
         * @link https://dev.getui.com/
         */
        'IGt_AppID'                 => '',
        'IGt_AppSecret'             => '',
        'IGt_AppKey'                => '',
        'IGt_MasterSecret'          => '',
    ],
    'IGt_staff' => [
        // IGt 推送配置
        /**
         * @online
         * @link https://dev.getui.com/
         */
        'IGt_AppID'                 => '',
        'IGt_AppSecret'             => '',
        'IGt_AppKey'                => '',
        'IGt_MasterSecret'          => '',
    ],
    'payConfig' => [
        // 微信支付参数
        'wechat' => [
            // 沙箱模式
            'debug'      => false,
            // 应用ID
            'app_id'     => '1561352391',
            // 微信支付商户号
            'mch_id'     => 'wx1288370bcddf64a6',
            /*
             // 子商户公众账号ID
             'sub_appid'  => '子商户公众账号ID,需要的时候填写',
             // 子商户号
             'sub_mch_id' => '子商户号,需要的时候填写',
            */
            // 微信支付密钥
            'mch_key'    => 'cb4ea189b371f36787f74253aee05aae',
            // 微信证书 cert 文件
            'ssl_cer'    => __DIR__ . '/cert/apiclient_cert.pem',
            // 微信证书 key 文件
            'ssl_key'    => __DIR__ . '/cert/apiclient_key.pem',
            // 缓存目录配置
            'cache_path' => '',
            // 支付成功通知地址
            'notify_url' => 'https://api.dajxyl.com/notify/wx',
            // 网页支付回跳地址
            'return_url' => 'https://api.dajxyl.com/notify/wx',
        ],

        // 支付宝支付参数 (沙箱)
        'alipay' => [
            // 沙箱模式
            'debug'       => false,
            // 应用ID
            'app_id'      => '2019102568579960',
            // 支付宝公钥(1行填写)
            'public_key'  => 'MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAwEJD0NfXii+MrXXZlKJ81Q7nK1g/SXGEyUEoFOOn21tKjip+475fgPr+hHDNrmwMc6M8OLJMMtr6gR5UkYNVOL8YaQzzRpHUfvn1hI5KsqPm8amiRohwJTcttbfmME1wDSEX6IJ2Os9hvd14+XL/AVHUDxzuEb1ZvGIEEQlGW7DGtGvI1nhyAeCuKajeLeJjxXFGAsNic6LUcTnqGZbwxqMX6ZiRwrLGHvdteOdVLC66f5otUEToqP9MCN37vWiDzzMXlbSqFfX/mj6y5PByFRtP8lpkydvFImhndbSmt/cQmaLyx4G+6HWfxTVJTqNaS/S9G3k2K5vfxJe5g2CpewIDAQAB',
            // 支付宝私钥(1行填写)
            'private_key' => 'MIIEvwIBADANBgkqhkiG9w0BAQEFAASCBKkwggSlAgEAAoIBAQDAQkPQ19eKL4ytddmUonzVDucrWD9JcYTJQSgU46fbW0qOKn7jvl+A+v6EcM2ubAxzozw4skwy2vqBHlSRg1U4vxhpDPNGkdR++fWEjkqyo+bxqaJGiHAlNy21t+YwTXANIRfognY6z2G93Xj5cv8BUdQPHO4RvVm8YgQRCUZbsMa0a8jWeHIB4K4pqN4t4mPFcUYCw2JzotRxOeoZlvDGoxfpmJHCssYe921451UsLrp/mi1QROio/0wI3fu9aIPPMxeVtKoV9f+aPrLk8HIVG0/yWmTJ28UiaGd1tKa39xCZovLHgb7odZ/FNUlOo1pL9L0beTYrm9/El7mDYKl7AgMBAAECggEAVbs20mHtU0lwycjLhWQPllJW8xUe43kjZTsQzH/X0hEbZdm9S4EQxUsnQ5epoCW+R7J6oC2hnOvY2MrVmy2dSvirwexsbwOIZjbALKPm21ILIagrHJiqqW25jFa85r0hQjmHl77VSdRAGZIw58tHuybqEPMtleuBoGd0uMQSA8BBuB6jH4c54JRtVXDanyo9i5rgRUWZn/+gjoPR65I2OevckKreZ9B9Mkd3mRr0nfOIocUc4zZliJ7JmkdNWA7Ge2gnIDkKCHP5nzv6g4Rykv3BOtiY6jSTJHgakljaWB2cADuWRh6K7jrtczKLAP43PGBeqU++RKsnwt/xNHLjgQKBgQDybtLuYp58QOozaTOTs/XO/yUc5IK0CNQGaku7iDx+FigS3Xh4ofTG3wU3f8fjyb9o7VJWWQ4uc8z4Cb3FTmCQlNr6wkkJGYdsR0v4vM4rKuujxNc3vbuzm+xquv0Q3/r9Glfh/HnjuJ/DH9zojc1JwdNMR+y/PS7ISLVL+fXqmQKBgQDLBKFf5lct9YmGOnt1FZkTSWmPXNoqMs2tvJuf5DiVe41kzmPxcICQSjT65CWPTOtNLhY8OkBAax6vuJ43+ydbxGmcOhXU+M4lRXGgKWeIO9NpPygKMX/j5P40ACLEBHxJDooCjVGSDWAGtb5t5a/wfZcB4D89o0nfgfvmqmN1MwKBgQCM7H8Qs6MM928sk2q34VRyDz6znOGdZcRaNk/vozIG2TpSPQtalEqFj/6oVE8NyqjJharnJr1no0jypjb6CqV3ZhAk0+tAruZZutgeryHpVfnEKRgx/sitj2XOZQPWW1y65CVR6EGybg/wjQUM6eD7jwAUx3qHcDlRk3JPx+17gQKBgQClipYHu6v0ttU31XIby8uxFVh05PKkHB7ofvWrEA4vnbpyq3SFSAYdIdVHi0cxLThlC6Jn49vGa1JvWKvy2+GBC4xOLnLk4Sg+7fwz6+8XACloFW6RuUEeU/gP8NhoW3v4mllgsVkFLdDSR9oKhJLNF6tNhUwr93ziOnxr3x4QTwKBgQC4Ms7JclF1tSVfIcHsGjl5k1jw3XDjktZilKGawwnJu9vWArfoJyx+SV0NnVyFHfxqU0gy+5zbJCZzV7EF3MpBKjhAeniA3me3+FI2yR1VyrwJq92PzEKnsbxhO88nKzYqTMzs2UGtsVChAPoZctwzoNAoqgjyU8ApXMZdDXNgUw==',
            // 缓存目录配置
            'cache_path'  => '',
            // 支付成功通知地址
            'notify_url'  => 'https://api.dajxyl.com/notify/alipay',
            // 网页支付回跳地址
            'return_url'  => 'https://api.dajxyl.com/notify/alipay',
        ],
    ],
];

11.3 /home/www/dajx-api/config/__localDb.php

<?php

return [
    'class' => 'yii\db\Connection',
    'dsn' => 'mysql:host=localhost;dbname=dajx-api',
    'username' => 'root',
    'password' => 'root123.',
    'charset' => 'utf8',
];

11.4 /home/www/dajx-api/config/__localDb2.php

<?php

return [
    'class' => 'yii\db\Connection',
    'dsn' => 'mysql:host=localhost;dbname=biglove',
    'username' => 'root',
    'password' => 'root123.',
    'charset' => 'utf8',
];

11.5 /home/www/dajx-api/config/__params.php

<?php

return [
    'payConfig' => [
        // 微信支付参数
        'wechat' => [
            // 沙箱模式
            'debug'      => false,
            // 应用ID
            'app_id'     => '1561352391',
            // 微信支付商户号
            'mch_id'     => 'wx1288370bcddf64a6',
            /*
             // 子商户公众账号ID
             'sub_appid'  => '子商户公众账号ID,需要的时候填写',
             // 子商户号
             'sub_mch_id' => '子商户号,需要的时候填写',
            */
            // 微信支付密钥
            'mch_key'    => 'cb4ea189b371f36787f74253aee05aae',
            // 微信证书 cert 文件
            'ssl_cer'    => __DIR__ . '/cert/apiclient_cert.pem',
            // 微信证书 key 文件
            'ssl_key'    => __DIR__ . '/cert/apiclient_key.pem',
            // 缓存目录配置
            'cache_path' => '',
            // 支付成功通知地址
            'notify_url' => 'https://api.dajxyl.com/notify/wx',
            // 网页支付回跳地址
            'return_url' => 'https://api.dajxyl.com/notify/wx',
        ],

        // 支付宝支付参数 (沙箱)
        'alipay' => [
            // 沙箱模式
            'debug'       => false,
            // 应用ID
            'app_id'      => '2019102568579960',
            // 支付宝公钥(1行填写)
            'public_key'  => 'MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAwEJD0NfXii+MrXXZlKJ81Q7nK1g/SXGEyUEoFOOn21tKjip+475fgPr+hHDNrmwMc6M8OLJMMtr6gR5UkYNVOL8YaQzzRpHUfvn1hI5KsqPm8amiRohwJTcttbfmME1wDSEX6IJ2Os9hvd14+XL/AVHUDxzuEb1ZvGIEEQlGW7DGtGvI1nhyAeCuKajeLeJjxXFGAsNic6LUcTnqGZbwxqMX6ZiRwrLGHvdteOdVLC66f5otUEToqP9MCN37vWiDzzMXlbSqFfX/mj6y5PByFRtP8lpkydvFImhndbSmt/cQmaLyx4G+6HWfxTVJTqNaS/S9G3k2K5vfxJe5g2CpewIDAQAB',
            // 支付宝私钥(1行填写)
            'private_key' => 'MIIEvwIBADANBgkqhkiG9w0BAQEFAASCBKkwggSlAgEAAoIBAQDAQkPQ19eKL4ytddmUonzVDucrWD9JcYTJQSgU46fbW0qOKn7jvl+A+v6EcM2ubAxzozw4skwy2vqBHlSRg1U4vxhpDPNGkdR++fWEjkqyo+bxqaJGiHAlNy21t+YwTXANIRfognY6z2G93Xj5cv8BUdQPHO4RvVm8YgQRCUZbsMa0a8jWeHIB4K4pqN4t4mPFcUYCw2JzotRxOeoZlvDGoxfpmJHCssYe921451UsLrp/mi1QROio/0wI3fu9aIPPMxeVtKoV9f+aPrLk8HIVG0/yWmTJ28UiaGd1tKa39xCZovLHgb7odZ/FNUlOo1pL9L0beTYrm9/El7mDYKl7AgMBAAECggEAVbs20mHtU0lwycjLhWQPllJW8xUe43kjZTsQzH/X0hEbZdm9S4EQxUsnQ5epoCW+R7J6oC2hnOvY2MrVmy2dSvirwexsbwOIZjbALKPm21ILIagrHJiqqW25jFa85r0hQjmHl77VSdRAGZIw58tHuybqEPMtleuBoGd0uMQSA8BBuB6jH4c54JRtVXDanyo9i5rgRUWZn/+gjoPR65I2OevckKreZ9B9Mkd3mRr0nfOIocUc4zZliJ7JmkdNWA7Ge2gnIDkKCHP5nzv6g4Rykv3BOtiY6jSTJHgakljaWB2cADuWRh6K7jrtczKLAP43PGBeqU++RKsnwt/xNHLjgQKBgQDybtLuYp58QOozaTOTs/XO/yUc5IK0CNQGaku7iDx+FigS3Xh4ofTG3wU3f8fjyb9o7VJWWQ4uc8z4Cb3FTmCQlNr6wkkJGYdsR0v4vM4rKuujxNc3vbuzm+xquv0Q3/r9Glfh/HnjuJ/DH9zojc1JwdNMR+y/PS7ISLVL+fXqmQKBgQDLBKFf5lct9YmGOnt1FZkTSWmPXNoqMs2tvJuf5DiVe41kzmPxcICQSjT65CWPTOtNLhY8OkBAax6vuJ43+ydbxGmcOhXU+M4lRXGgKWeIO9NpPygKMX/j5P40ACLEBHxJDooCjVGSDWAGtb5t5a/wfZcB4D89o0nfgfvmqmN1MwKBgQCM7H8Qs6MM928sk2q34VRyDz6znOGdZcRaNk/vozIG2TpSPQtalEqFj/6oVE8NyqjJharnJr1no0jypjb6CqV3ZhAk0+tAruZZutgeryHpVfnEKRgx/sitj2XOZQPWW1y65CVR6EGybg/wjQUM6eD7jwAUx3qHcDlRk3JPx+17gQKBgQClipYHu6v0ttU31XIby8uxFVh05PKkHB7ofvWrEA4vnbpyq3SFSAYdIdVHi0cxLThlC6Jn49vGa1JvWKvy2+GBC4xOLnLk4Sg+7fwz6+8XACloFW6RuUEeU/gP8NhoW3v4mllgsVkFLdDSR9oKhJLNF6tNhUwr93ziOnxr3x4QTwKBgQC4Ms7JclF1tSVfIcHsGjl5k1jw3XDjktZilKGawwnJu9vWArfoJyx+SV0NnVyFHfxqU0gy+5zbJCZzV7EF3MpBKjhAeniA3me3+FI2yR1VyrwJq92PzEKnsbxhO88nKzYqTMzs2UGtsVChAPoZctwzoNAoqgjyU8ApXMZdDXNgUw==',
            // 缓存目录配置
            'cache_path'  => '',
            // 支付成功通知地址
            'notify_url'  => 'https://api.dajxyl.com/notify/alipay',
            // 网页支付回跳地址
            'return_url'  => 'https://api.dajxyl.com/notify/alipay',
        ],
    ],
    'IGt' => [
        // IGt 推送配置
        /**
         * @local 本地方式
         * @link https://dev.getui.com/
         */
        'IGt_AppID'                 => '',
        'IGt_AppSecret'             => '',
        'IGt_AppKey'                => '',
        'IGt_MasterSecret'          => '',
    ],
    /*阿里云SMS短信配置*/
    'AliyunSMS' => [
        'accessKeyId' => 'LTAI4Fhkppt6hhyr8YKXYPSH',
        'accessKeySecret' => 'cSVFu7IHR1WEd1SEEdBeFP5ym0TV1i',
        'SignName' => '大爱金孝',
        'TemplateCode_register' => 'SMS_177225079',
        'TemplateCode_login' => 'SMS_177225081',
        'TemplateCode_forget' => 'SMS_177256093',
        'TemplateCode_beadhouse' => 'SMS_177251139',
        'TemplateCode_beadhouseMan' => 'SMS_177241213',
        'TemplateCode_volunteer' => 'SMS_177241214',
        'TemplateCode_rescue' => 'SMS_177251140',
        'TemplateCode_verify_tel' => 'SMS_177225082',
        'TemplateCode_update_tel' => 'SMS_177225077',
    ],
];

11.6 /home/www/dajx-staff-api/config/__params.php

<?php

return [
    'key' => 'eson',
    /*阿里云SMS短信配置*/
    'AliyunSMS' => [
        'accessKeyId' => 'LTAI4Fhkppt6hhyr8YKXYPSH',
        'accessKeySecret' => 'cSVFu7IHR1WEd1SEEdBeFP5ym0TV1i',
        'SignName' => '大爱金孝员工端',
        'TemplateCode_login' => 'SMS_177225081',
        'TemplateCode_forget' => 'SMS_177256093',
        'TemplateCode_verify_tel' => 'SMS_177225082',
        'TemplateCode_update_tel' => 'SMS_177225077',
    ],
    'IGt_staff' => [
        // IGt 推送配置
        /**
         * @link https://dev.getui.com/
         */
        'IGt_AppID'                 => '',
        'IGt_AppSecret'             => '',
        'IGt_AppKey'                => '',
        'IGt_MasterSecret'          => '',
    ],

    'IGt_app'=> [
        'IGt_AppID'                 => '',
        'IGt_AppSecret'             => '',
        'IGt_AppKey'                => '',
        'IGt_MasterSecret'          => '',
    ],
];

11.7 /home/www/dajx-staff-api/config/__localDb.php

<?php

return [
    'class' => 'yii\db\Connection',
    'dsn' => 'mysql:host=localhost;dbname=dajx-api',
    'username' => 'root',
    'password' => 'root123.',
    'charset' => 'utf8',
];

12 完成 赶快开始使用吧 ~

https://api.dajxyl.com/ - 客户端API https://apistaff.dajxyl.com/ - 员工端API https://admin.dajxyl.com/ - 后台CMS管理

核心竞争力

关于商城管理后台前端

点赞(0) 阅读(1) 举报
目录
标题