当前位置: 首页 > wzjs >正文

网站建设推广优化话术网络品牌推广

网站建设推广优化话术,网络品牌推广,建设摩托车官网报价表,wordpress apk 中文版1、前言 讲解在Mac环境下,ThingsBoard本地源代码安装和运行的过程和问题的解决 2、ThingsBoard中文网文档 安装的文档主要借鉴ThingsBoard中文网文档: 源代安装 | ThingsBoard社区版http://www.ithingsboard.com/docs/user-guide/install/building-fro…

1、前言

讲解在Mac环境下,ThingsBoard本地源代码安装和运行的过程和问题的解决

2、ThingsBoard中文网文档

安装的文档主要借鉴ThingsBoard中文网文档:

源代安装 | ThingsBoard社区版icon-default.png?t=N7T8http://www.ithingsboard.com/docs/user-guide/install/building-from-source/#%E5%AE%89%E8%A3%85%E5%8C%85

3、前置环境

为了还原实际部署可能遇到的问题,我使用的是本机已下载的环境展开讲解。

3.1、Java版本

11.0.18

3.2、Maven版本

3.9.5

3.3、node版本

v21.5.0

3.3.1、node版本切换

如果node版本有报错过低,则可以切换版本,node版应该至少v16.5.0。

3.3.3.1、安装node版本管理模块
// 安装方式以下三选一
// 使用 npm
sudo npm install n -g
//  yarn
yarn global add n
// 使用 brew
brew install n
3.3.3.2、管理模块指定node版本
sudo n 版本

3.4、npm版本

10.2.4

3.5、yarn版本

4、安装编译

4.1、克隆代码

clone成功后,先不要去编辑器中运行,最好先命令(控制台命令)编译好,因为需要下载很多依赖,编译安装的过程中也会生成一些类,直接打开会报错。

git clone https://github.com/thingsboard/thingsboard.git
cd thingsboard

4.2、编译运行

在thingsboard项目目录下运行maven install指令开始编译安装:

mvn clean install -DskipTests

4.3、出现的编译失败

4.3.1、报错内容

[INFO] --- frontend:1.12.0:yarn (yarn pkg) @ web-ui ---
[INFO] Running 'yarn run pkg' in /Users/lidongbin/code/java/thingsboard/msa/web-ui
[INFO] yarn run v1.22.17
[INFO] $ tsc && pkg -t node16-linux-x64,node16-win-x64 --out-path ./target ./target/src && node install.js
[INFO] > pkg@5.7.0
[INFO] > Fetching base Node.js binaries to PKG_CACHE_PATH
[INFO] > Not found in remote cache:
[INFO]   {"tag":"v3.4","name":"node-v16.15.0-linux-x64"}
[INFO] > Building base binary from source:
[INFO]   built-v16.15.0-linux-x64
[INFO] > Error! Not able to build for 'linux' here, only for 'macos'
[INFO] info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

[ERROR] Failed to execute goal com.github.eirslett:frontend-maven-plugin:1.12.0:yarn (yarn pkg) on project web-ui: Failed to run task: 'yarn run pkg' failed. org.apache.commons.exec.ExecuteException: Process exited with an error: 2 (Exit value: 2) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <args> -rf :web-ui

4.2.2、报错问题

pkg-cache下没有对应mac版本的node16.5.0版本的pkg相关文件。

4.2.3、问题解决

我们可以通过下载对应的pkg-cache相关文件来避免此错误。

4.2.3.1、切换版本

参考3.3.1、node版本切换

4.2.3.2、pkg-cache相关文件下载和使用

pkg-cache相关文件下载地址(vercel/pkg-fetch · GitHub)A utility to fetch or build patched Node binaries used by `pkg` to generate executables. This repo hosts prebuilt binaries in Releases. - Releases · vercel/pkg-fetchicon-default.png?t=N7T8https://github.com/vercel/pkg-fetch/releases找到node16.5.0版本的assets,将linux,macos,win都下载(其实在mac下只需要macos)。

将下载后的文件,重命名为

  • 将node-v16.15.0-macos-x64更名为fetched-v16.15.0-macos-x64
  • 将node-v16.15.0-linux-x64更名为fetched-v16.15.0-linux-x64
  • 将node-v16.15.0-win-x64更名为fetched-v16.15.0-win-x64

然后放入~\.pkg-chche\3.4目录中。

 4.2.3.3、重新编译
mvn clean install -DskipTests

5、运行

在IDEA中打开项目,并修改thingsboard.yml中数据库相关配置,替换用户名密码。

截屏2023-12-01 10.39.16.png

dao模块下,sql文件拷贝至application模块data/sql目录中

截屏2023-12-01 10.46.59.png

运行 ThingsboardInstallApplication,完成thingsboard表结构和数据的初始化。默认情况下,使用系统管理员sysadmin@thingsboard.orgsysadmin进行登录 。当然,初始化用户可以在配置文件中自定义。

截屏2023-12-01 10.46.16.png

接着运行ThingsboardServerApplication,访问http://localhost:8080/ 自动跳转至登录页面

截屏2023-12-01 10.49.11.png

http://www.dtcms.com/wzjs/4762.html

相关文章:

  • 网站开发需要多少人网站结构
  • 做阿里巴巴网站卖货咋样1688黄页大全进口
  • 用jsp建设网站高端seo服务
  • 网站如何做社群网络营销战略
  • 做搞机网站google推广及广告优缺点
  • 做网站准备什么软件山东济南最新消息
  • 建站abc后台登录aso优化吧
  • 长沙优化网站分析谷歌seo快速排名软件首页
  • wordpress中文手册pdf快排seo排名软件
  • 网页开发用到的技术seox
  • 网站的建设费用分为网络推广平台有哪些
  • 徐州商城网站建设长治网站seo
  • 新手怎样做网站推广网站建设与管理主要学什么
  • 广告营销策划是做什么的网站关键词排名优化
  • 做宣传可以在哪些网站上发布seo怎么学在哪里学
  • joomla网站模板网站推广的工作内容
  • 啥是东莞网站制作公司公关策划公司
  • 政府三级网站制度建设营销型网站设计制作
  • 做mla的网站网络营销的宏观环境
  • 浙江网站搭建广东网络优化推广
  • 网站建设 爱诚科技公司百度客服转人工
  • 网站设计怎么算间距写软文的平台有哪些
  • seo优化网站建设哪家好黑帽seo排名
  • 怎样做网站性能优化东莞网站推广哪里找
  • 网站设计中主题有哪些作用荥阳seo
  • 做美食网站的需求分销平台
  • 诸暨北京有哪些网站制作公司网络优化工程师前景
  • 黄山找人做网站班级优化大师官网下载
  • 做网站基本百度集团总部在哪里
  • 网站要怎么备案电商平台运营方案