首页 > 编程语言 >拯救php性能的神器webman-使用后台webman-admin

拯救php性能的神器webman-使用后台webman-admin

时间:2024-03-15 11:55:06浏览次数:27  
标签:Plugin webman support Locking Installing admin install php Extracting

在webman的插件市场里面发现了这个 webman-admin

安装的话很简单,就是在已经安装了 webman 的目录里面执行  composer require -W webman/admin 

安装过程提示这些

Using version ^0.6.24 for webman/admin
./composer.json has been updated
Running composer update webman/admin --with-all-dependencies
Loading composer repositories with package information
Updating dependencies
Lock file operations: 34 installs, 0 updates, 0 removals
  - Locking brick/math (0.12.1)
  - Locking carbonphp/carbon-doctrine-types (2.1.0)
  - Locking doctrine/inflector (2.0.10)
  - Locking guzzlehttp/guzzle (7.8.1)
  - Locking guzzlehttp/promises (2.0.2)
  - Locking guzzlehttp/psr7 (2.6.2)
  - Locking illuminate/bus (v10.48.2)
  - Locking illuminate/collections (v10.48.2)
  - Locking illuminate/conditionable (v10.48.2)
  - Locking illuminate/container (v10.48.2)
  - Locking illuminate/contracts (v10.48.2)
  - Locking illuminate/database (v10.48.2)
  - Locking illuminate/events (v10.48.2)
  - Locking illuminate/macroable (v10.48.2)
  - Locking illuminate/pagination (v10.48.2)
  - Locking illuminate/pipeline (v10.48.2)
  - Locking illuminate/support (v10.48.2)
  - Locking intervention/image (2.7.2)
  - Locking nesbot/carbon (2.72.3)
  - Locking psr/clock (1.0.0)
  - Locking psr/http-client (1.0.3)
  - Locking psr/http-factory (1.0.2)
  - Locking psr/http-message (2.0)
  - Locking psr/simple-cache (3.0.0)
  - Locking ralouphie/getallheaders (3.0.3)
  - Locking symfony/deprecation-contracts (v3.4.0)
  - Locking symfony/polyfill-mbstring (v1.29.0)
  - Locking symfony/polyfill-php80 (v1.29.0)
  - Locking symfony/translation (v6.4.4)
  - Locking symfony/translation-contracts (v3.4.1)
  - Locking voku/portable-ascii (2.0.1)
  - Locking webman/admin (v0.6.24)
  - Locking webman/captcha (v1.0.2)
  - Locking webman/event (v1.0.5)
Writing lock file
Installing dependencies from lock file (including require-dev)
Package operations: 34 installs, 0 updates, 0 removals
  - Installing brick/math (0.12.1): Extracting archive
  - Installing guzzlehttp/promises (2.0.2): Extracting archive
  - Installing ralouphie/getallheaders (3.0.3): Extracting archive
  - Installing psr/http-message (2.0): Extracting archive
  - Installing psr/http-factory (1.0.2): Extracting archive
  - Installing guzzlehttp/psr7 (2.6.2): Extracting archive
  - Installing voku/portable-ascii (2.0.1): Extracting archive
  - Installing symfony/translation-contracts (v3.4.1): Extracting archive
  - Installing symfony/polyfill-mbstring (v1.29.0): Extracting archive
  - Installing symfony/deprecation-contracts (v3.4.0): Extracting archive
  - Installing symfony/translation (v6.4.4): Extracting archive
  - Installing symfony/polyfill-php80 (v1.29.0): Extracting archive
  - Installing psr/clock (1.0.0): Extracting archive
  - Installing carbonphp/carbon-doctrine-types (2.1.0): Extracting archive
  - Installing nesbot/carbon (2.72.3): Extracting archive
  - Installing illuminate/macroable (v10.48.2): Extracting archive
  - Installing psr/simple-cache (3.0.0): Extracting archive
  - Installing illuminate/contracts (v10.48.2): Extracting archive
  - Installing illuminate/conditionable (v10.48.2): Extracting archive
  - Installing illuminate/collections (v10.48.2): Extracting archive
  - Installing doctrine/inflector (2.0.10): Extracting archive
  - Installing illuminate/support (v10.48.2): Extracting archive
  - Installing illuminate/pipeline (v10.48.2): Extracting archive
  - Installing illuminate/bus (v10.48.2): Extracting archive
  - Installing illuminate/container (v10.48.2): Extracting archive
  - Installing psr/http-client (1.0.3): Extracting archive
  - Installing webman/event (v1.0.5): Extracting archive
  - Installing webman/captcha (v1.0.2): Extracting archive
  - Installing intervention/image (2.7.2): Extracting archive
  - Installing illuminate/pagination (v10.48.2): Extracting archive
  - Installing illuminate/events (v10.48.2): Extracting archive
  - Installing illuminate/database (v10.48.2): Extracting archive
  - Installing guzzlehttp/guzzle (7.8.1): Extracting archive
  - Installing webman/admin (v0.6.24): Extracting archive
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
Create config/plugin/webman/event
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
> support\Plugin::install
Create plugin/admin
17 package suggestions were added by new dependencies, use `composer suggest` to see details.
Generating autoload files
16 packages you are using are looking for funding.
Use the `composer fund` command to find out more!
View Code

服务要重新启动一下  php start.php start 

由于我们之前将监听端口改为了 127.0.0.1:8787,所以这里可以直接访问  http://127.0.0.1:8787/app/admin 

可以看到这样的安装界面

然后就按照这个配置一下,填数据库密码,然后下一步,提示这个

这就配置一下后台用户和密码就行了

好了,提示是需要重启后才能生效。

不过我这里没重启,也能进入后台,看到登录界面。

然后就拿刚刚的用户名称和密码登录进去呗。

然后就是这个后台首页了

 随便点了几个页面,感觉后台不错。

 这还有个构建表单的页面,挺好

然后我就想这个地方监控了8787端口 ,总不能一直这样访问吧。还是配置个虚拟域名吧。

然后就是老生长谈了。

编辑host  sudo gedit /etc/hosts 

增加一行  127.0.0.1 local.webmanadmin.com 

增加文件  sudo touch /etc/nginx/sites-available/local.webmanadmin.com.conf 

编辑文件内容如下:

server {
    listen 80;
    index index.php index.html index.htm index.nginx-debian.html;
    server_name local.webmanadmin.com;
        location / {
        proxy_set_header Host $http_host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        # 转发Cookie,设置 SameSite
        proxy_cookie_path / "/; secure; HttpOnly; SameSite=strict";
        # 执行代理访问真实服务器
        proxy_pass http://127.0.0.1:8787;
        }
}

来到文件夹  cd /etc/nginx/sites-enabled 

设置软链接  sudo ln -s /etc/nginx/sites-available/local.webmanadmin.com.conf local.webmanadmin.com.conf 

然后重启 nginx  sudo systemctl restart nginx.service 

然后就访问 

我发现登录的时候验证码总是提示错误,后来我查了一下 把 nginx 配置里面的这个proxy_cookie_path改了一下 

 proxy_cookie_path /app/ /; 

之后重启nginx  sudo systemctl restart nginx.service 

重启webman  php start.php start 就好了。

我以为是这里path的问题,然后我又改回去了,又重新重启,发现登录没问题,感觉这里挺奇怪的,不过还好现在能登录也没问题了。

真是奇怪呢,不知道是不是哪儿的临时错误,验证码的问题现在又好了。哈哈!

标签:Plugin,webman,support,Locking,Installing,admin,install,php,Extracting
From: https://www.cnblogs.com/lizhaoyao/p/18075112

相关文章

  • mac 下Fastadmin 框架搭建
    1.总体思路将fastadmin源码下载到本地,服务器(nignx)绑定域名,host绑定,然后通过网址访问,进行可视化安装。其中出现了一些问题,主要是可视化安装时mysql报错了,数据库认证失败,确认账号密码没有问题,最终是php链接mysql时的认证方式不匹配造成环境安装接上一篇 具体如下1.fastadmin......
  • Django admin管理工具的使用、定制及源码解析
    Djangoadmin管理工具的使用、定制及源码解析admin组件使用Django提供了基于web的管理工具。Django自动管理工具是django.contrib的一部分。你可以在项目的settings.py中的INSTALLED_APPS看到它:#ApplicationdefinitionINSTALLED_APPS=['django.contrib.a......
  • php pdf转图片列表
    使用composerrequirespatie/pdf-to-image服务器需要安装ImageMagick,并且将/etc/ImageMagick-6/policy.xml找到pdf这一行,注释掉或者增加读、写、编译 <policydomain="coder"rights="read|write|decode"pattern="PDF"/>publicfunctionpdfToImage(RequestInterf......
  • CentOS-7部署PHP-7.4
    CentOS-7部署PHP-7.4使用CentOS-7-x86_64-Minimal-2009.iso安装一、常用操作1:关闭防火墙servicefirewalldstopsystemctldisablefirewalld2:启用登录密钥mkdir-p~/.ssh&&echo'ssh-ed25519AAAAC3NzaC1lZDI1NTE5AAAAINczVrP1nQt56KrtY0zFDRYvNGjMVS2MphwNWXH5j7ygxi......
  • PHP反序列化总结
    0x01.前言本文首发于先知:https://xz.aliyun.com/t/12507。花些时间把四种常见的php反序列化总结了一遍,各自都找了简单示例和例题,参考了一些师傅的链接加上自己的理解,参考链接放在文末0x02.反序列化是什么说到反序列化,经常会想到serialize(),unserialize()这两个函数。我看到......
  • PHP-CGI远程1代码执行漏洞(CVE-2012-1823)
    影响版本php<5.3.12orphp<5.4.2测试环境cdphp/cve-2012-1823docker-composeup-d访问http://your-ip:8080/index.php?-s即爆出源码,说明漏洞存在。发送如下数据包,可见Body中的代码已被执行:POST/index.php?-d+allow_url_include%3don+-d+auto_prepend_file%3dphp%3a......
  • php使用openssl生成公钥私钥
    1、确保你的PHP环境已经启用了OpenSSL扩展$config=array("digest_alg"=>"sha1","private_key_bits"=>1024,"private_key_type"=>OPENSSL_KEYTYPE_RSA,"config"=>�......
  • thinkphp 5 跨域问题解决
    版本:5.1.41LTS从网上搜到好多从/public/index.php添加heade信息,或者用中间件,或者添加behavior操作,可以做到解决跨域问题,但是亲身试验了都不行,今天刚找了一个,可以使用,放在这里header('Access-Control-Allow-Credentials:true');header('Access-Control-Allow-Methods:GET,......
  • php-构建自己的composer包
    【windows】版1.安装composer,选择PHP版本https://getcomposer.org/Composer-Setup.exe2.安装githttps://objects.githubusercontent.com/github-production-release-asset-2e65be/23216272/2d1c35e2-ece0-4287-bc51-b221f43922b4?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Cred......
  • PG14:adminpack 插件源码分析
    adminpack提供了大量支持功能,pgAdmin和其他管理工具可以使用这些功能提供额外功能,例如远程管理服务器日志文件。默认情况下,只有数据库超级用户才能使用所有这些功能,但其他用户也可以使用GRANT命令使用这些功能。我们先来看一下他支持的函数,可以通过\dx+adminpack来进行查......