1 Star 1 Fork 18

ThinkCsly / webim-layim

forked from Airoura / webim-layim 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
MIT

骆寻IM

Laravel + LayIM + GatewayWorker 开发的网页聊天系统。

新的改变

我们对之前的开源项目--极云赋进行了重构,新版本的项目结构更为清晰,数据库设计更为合理,程序语法更为简洁,易于拓展维护。新版本不仅包含了旧版本的全部功能,我们还增加了如下几点新功能,与时俱进:

  1. 前后端完全分离 ,本项目包含一个完整的 API 服务器和两个全新设计的客户端( PC 客户端和手机客户端);
  2. 全新的右键菜单;
  3. MySQL+MongoDB 双数据库配置,高性能的 MongoDB 负责存储大量的聊天记录和消息记录;
  4. 阿里云短信;
  5. 阿里云 OSS 存储大文件和图片;
  6. 应用 https 和 wss 传输协议;

项目截图

添加好友 在这里插入图片描述

在这里插入图片描述 在这里插入图片描述 在这里插入图片描述 在这里插入图片描述 在这里插入图片描述 在这里插入图片描述

项目结构

  • app
    • Concole ------------------------------------------------------包含应用所有自定义的 Artisan 命令
    • Http
      • Controllers/Api ----------------------------------------------------------处理所有通过接口进入应用的请求
      • Middleware --------------------------------------------------------------中间件
      • Requests -----------------------------------------------------------------请求验证类
      • Resources ---------------------------------------------------------------接口资源类
    • Providers ----------------------------------------------------------服务提供者类
    • Services -----------------------------------------------------------服务类
  • Applications/LuoXun ---------------------------------------GatewayWorker配置文件目录
  • config ----------------------------------------------------------------Laravel 配置文件目录
  • database
    • factories ---------------------------------------------------------- 数据库工厂目录
    • migrations -------------------------------------------------------- 数据库迁移文件目录
    • seeds -------------------------------------------------------------- 数据填充目录
  • public
    • plugins ------------------------------------------------------- 前端插件目录
    • layui ---------------------------------------------------------- 把包含 LayIM 的 Layui 放在这里
  • resources
    • css ------------------------------------------------------------ 前端 CSS 目录
    • js -------------------------------------------------------------- 前端 JS 目录
    • lang ---------------------------------------------------------- 多语言设置目录
    • views
      • mobile -------------------------------------------------------------- 手机客户端
      • pc ---------------------------------------------------------------------PC 客户端
      • index.blade.php -------------------------------------------------- 首页视图
      • login.blade.php --------------------------------------------------- 登录视图
      • reg.blade.php ----------------------------------------------------- 注册视图
  • routes - api ---------------------------------------------------------------- 接口路由 - web ---------------------------------------------------------------视图路由
  • .env ------------------------------------------------------ Laravel 全局配置文件

安装使用

我们假设你的服务器已经配置好了 Laravel 项目环境。

安装拓展包

composer update

打包 css/js

npm install
npm run production

编辑配置文件,把XXXX都填上

cp .env_example .env
vim .env

把包含 LayIM 的 layui 放在 /public 目录下

修改 /resources/views/pc/app.blade.php 和 /resources/views/mobile/app.blade.php 中的域名

var domain = ‘{Yourdomain}/wss’;

配置 nginx,解决 wss 协议问题

#laravel 框架 nginx 配置文件中的对根目录的访问修改为以下
location / {
	try_files $uri $uri/ /index.php?$query_string;
}
location /wss {
	proxy_pass localhost:5210;
	proxy_http_version 1.1;
	proxy_set_header Upgrade $http_upgrade;
	proxy_set_header Connection upgrade;
	proxy_set_header Host $host;
}

生成数据加密秘钥

php artisan key:generate

生成 jwt 令牌秘钥

php artisan jwt:secret

数据库迁移

php artisan migrate

填充用户和群组账号数据表

php artisan db:seed

上线项目

php artisan up

FAQ

  1. 为什么项目中不包含 LayIM 文件? LayIM 受国家计算机软件著作权保护,未经官网正规渠道授权不能公开产品源文件。当你获得 LayIM 后把包含 LayIM 的 layui 放在 /public 目录下即可。
  2. 为什么没有管理后台? 管理后台直接操作数据表,与项目中的请求处理逻辑无关。使用 laravel-admin 可以在十分钟内构建一个功能齐全的管理后台。
  3. 有没有配套文档? 旧版本有配套文档,新版本配套文档还在编写中。

捐赠

在这里插入图片描述

MIT License Copyright (c) 2021 luoxune Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

简介

Laravel 8 + LayIM 3.8 + GatewayWorker 开发的网页聊天系统。 展开 收起
MIT
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
1
https://gitee.com/ThinkCsly/webim-layim.git
git@gitee.com:ThinkCsly/webim-layim.git
ThinkCsly
webim-layim
webim-layim
main

搜索帮助