Canvas 再次安装中遇到的问题

时间:2022年07月15日

版本
yarn=1.19.1-1
node=14.0.0
bundler --version 1.13.6

RPC问题

git clone 下载代码一直报error: RPC failed; curl 18 transfer closed with outstanding read data remaining fatal: the remote end hung up unexpectedly错误的解决思路
http://hosts.gitcdn.top/

Parallel::UndumpableException

Parallel::UndumpableException: ActiveRecord::StatementInvalid: PG::UndefinedTable: ERROR: relation “public.brand_configs” does not exist
LINE 1: DELETE FROM “public”.“brand_configs” WHERE (NOT EXISTS (SELE

sudo COMPILE_ASSETS_BRAND_CONFIGS=0 RAILS_ENV=production bundle exec rake canvas:compile_assets

unknown attribute ‘singleton’ for Delayed::Backend::ActiveRecord::Job.

下面记混了,不太对应
dirname: missing operand
Try ‘dirname --help’ for more information.
stat: cannot stat ‘/…/config/environment.rb’: No such file or directory
su: Cannot fork user shell

sudo chown -R canvas public/dist/brandable_css

sudo /etc/init.d/canvas_init start

yarn版本问题

yarn错误The engine “node” is incompatible with this module

 yarn config set ignore-engines true
sudo yarn install --ignore-engines

https://www.jianshu.com/p/5cb4f48ed11b

bundle 版本问题

bundle莫名其妙提示2.1X版本,但需要的是2.2,已经安装这个版本,但不能运行,是bundle -v最初都是2.2,某次之后变成2.1了,按照下述删除就好了
https://cloud.tencent.com/developer/ask/sof/224941

加密随机字符串必须32位

qazwsxedcrfvtgbyhnujmiopkl123456

修改node版本方法

https://github.com/tj/n/issues/584
https://blog.csdn.net/zzq0523/article/details/122910368

Error while bundle install for idn-ruby

sudo apt-get install libldap2-dev
sudo apt-get install libidn11-dev

https://stackoverflow.com/questions/50055812/error-while-bundle-install-for-idn-ruby

unsplash-js 包版本不一致导致出错

npm list --depth=0
package.json 中需要6.3.0,但实际安装的是7.0.0,重新安装指定版本的
npm install unsplash-js@6.3.0 --legacy-peer-deps

启动之后,页面变成了目录

检查/var/log/apache2/error.log,报错信息如下,又执行一次passenger安装、配置

[ E 2022-07-15 20:46:57.5823 32138/T3v age/Cor/App/Implementation.cpp:211 ]: Cannot render an error page: Cannot open '/usr/share/passenger/templates/error_renderer/with_details/dist/styles.css' for reading: No such file or directory (errno=2)
     in 'void Passenger::ApplicationPool2::processAndLogNewSpawnException(Passenger::SpawningKit::SpawnException&, const Passenger::ApplicationPool2::Options&, const Passenger::ApplicationPool2::Context*)' (Implementation.cpp:187)
     in 'void Passenger::ApplicationPool2::Group::spawnThreadRealMain(const SpawnerPtr&, const Passenger::ApplicationPool2::Options&, unsigned int)' (SpawningAndRestarting.cpp:95)

[ E 2022-07-15 20:46:57.5823 32138/T3v age/Cor/App/Implementation.cpp:221 ]: Could not spawn process for application /var/canvas: An internal error occurred while preparing to start a preloader process: Support binary PassengerAgent not found (tried: /usr/lib/passenger/support-binaries/PassengerAgent and /root/.passenger/support-binaries/6.0.2/PassengerAgent)
  Error ID: fb183ab1

HTTPS ssl unable to verify the first certificate

rce的配置文件.env增加 NODE_TLS_REJECT_UNAUTHORIZED=0

FetchError: request to https://lms.xxx.edu.cn/api/v1/courses/1/pages?sort=title&per_page=50 failed, reason: unable to verify the first certificate
    at ClientRequest.<anonymous> (/var/canvas-rce-api/node_modules/node-fetch/lib/index.js:1461:11)
    at ClientRequest.emit (node:events:527:28)

FATAL: role “root” does not exist

delayed_job.log报错FATAL: role "root" does not exist,网上搜索都说是postgresql不能root启动,创建root账号登都无效。
进入log目录ll查看发现delayed_job.log文件所有权是root,production.log所有权是canvas,
切换用户su -u canvas,重启解决

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 4
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 4
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值