Discourse更新报错,Launcher无法启动


(Ares X) #1

在后台更新docker manager的日志,一直卡在最后一行

Skipping: locales/ca-c70bf7ec217277387cb55f8444a5d4a9202a2de93e740455b953dc807ac1bef0.js already compressed
Skipping: pretty-text-bundle-7d92d5aacd85eb445e7f245d29924d6a9bac79e1e34ded770e925f387511e99c.js already compressed
Compressing: application-e43127381df18eac19c99779ceccdd8802610a273269ccda5d20b38e13e9f2c0.js
uglifyjs '/var/www/discourse/public/assets/_application-e43127381df18eac19c99779ceccdd8802610a273269ccda5d20b38e13e9f2c0.js' -p relative -c -m -o '/var/www/discourse/public/assets/application-e43127381df18eac19c99779ceccdd8802610a273269ccda5d20b38e13e9f2c0.js' --source-map-root '/assets' --source-map '/var/www/discourse/public/assets/application-e43127381df18eac19c99779ceccdd8802610a273269ccda5d20b38e13e9f2c0.js.map' --source-map-url '/assets/application-e43127381df18eac19c99779ceccdd8802610a273269ccda5d20b38e13e9f2c0.js.map'

进入系统的/var/discourse目录下执行./launcher报错:


root@parrotsec:/var/discourse# ./launcher
/usr/bin/docker: Error response from daemon: connection error: desc = "transport: dial unix /var/run/docker/containerd/docker-containerd.sock: connect: connection refused": unknown.
ERRO[0001] error waiting for container: context canceled
Your Docker installation is not working correctly

See: https://meta.discourse.org/t/docker-error-on-bootstrap/13657/18?u=sam


(Schrödinger's Corgi) #2

./launcher 的用法
#!/bin/bash

usage () {
  echo "Usage: launcher COMMAND CONFIG [--skip-prereqs] [--docker-args STRING]"
  echo "Commands:"
  echo "    start:      Start/initialize a container"
  echo "    stop:       Stop a running container"
  echo "    restart:    Restart a container"
  echo "    destroy:    Stop and remove a container"
  echo "    enter:      Open a shell to run commands inside the container"
  echo "    logs:       View the Docker logs for a container"
  echo "    bootstrap:  Bootstrap a container for the config based on a template"
  echo "    rebuild:    Rebuild a container (destroy old, bootstrap, start new)"
  echo "    cleanup:    Remove all containers that have stopped for > 24 hours"
  echo
  echo "Options:"
  echo "    --skip-prereqs             Don't check launcher prerequisites"
  echo "    --docker-args              Extra arguments to pass when running docker"
  echo "    --skip-mac-address         Don't assign a mac address"
  exit 1
}

建议rebuild 再试一下 ./launcher rebuild app


(Ares X) #3

现在的问题是launcher无法运行,不管执行什么命令都会出现

/usr/bin/docker: Error response from daemon: connection error: desc = "transport: dial unix /var/run/docker/containerd/docker-containerd.sock: connect: connection refused": unknown.
ERRO[0001] error waiting for container: context canceled
Your Docker installation is not working correctly

See: https://meta.discourse.org/t/docker-error-on-bootstrap/13657/18?u=sam

(Schrödinger's Corgi) #4

思路:
检查是docker本身的问题还是discourse引起的docker报错(后台更新出错很可能是dicourse导致的,此时应将app.yml 中额外添加的插件plugins 暂时禁用,再次尝试)

1. Docker debug

docker -D run hello-world

2. discourse debug

Troubleshooting

View the container logs: ./launcher logs app

如果报错可以直接手动到 /var/discourse/shared/standalone/log 里查看

以上只是帮你分析,也许并不能帮你解决问题,从你有限的信息中我也无法推断,因为这个问题我没遇到过。


(Ares X) #5

docker -D run hello-world回显:

docker -D run hello-world
DEBU[0000] [hijack] End of stdout
docker: Error response from daemon: connection error: desc = "transport: dial unix /var/run/docker/containerd/docker-containerd.sock: connect: connection refused": unknown.