升级旧版本 2.8.5 遇到的问题

恰好我们已经很久没有更新 Discourse 了。我们目前停留在 v2.8.5 版本。我最近发现 Discourse 早就超过 3.0 版本了。
我想更新到最新版本,但眼下,我至少想更新到最新的 2.8.x 版本——2.8.14。
这里有一个大问题。当我重建时,Discourse 会更新基础镜像,然后我收到以下错误:

FAILED
--------------------
Pups::ExecError: grep -q 'outlets/before-server' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The "before-server" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 ) failed with return #<Process::Status: pid 300 exit 1>
Location of failure: /usr/local/lib/ruby/gems/3.3.0/gems/pups-1.3.0/lib/pups/exec_command.rb:131:in `spawn'
exec failed with the params {"cmd"=>["cp $home/config/nginx.sample.conf /etc/nginx/conf.d/discourse.conf", "rm /etc/nginx/sites-enabled/default", "mkdir -p /var/nginx/cache", "grep -q 'outlets/before-server' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The \\"before-server\\" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 )", "grep -q 'outlets/server' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The \\"server\\" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 )", "grep -q 'outlets/discourse' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The \\"discourse\\" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 )", "mkdir -p /etc/nginx/conf.d/outlets/before-server", "touch /etc/nginx/conf.d/outlets/before-server/20-redirect-http-to-https.conf", "touch /etc/nginx/conf.d/outlets/before-server/30-ratelimited.conf", "mkdir -p /etc/nginx/conf.d/outlets/server", "touch /etc/nginx/conf.d/outlets/server/10-http.conf", "touch /etc/nginx/conf.d/outlets/server/20-https.conf", "touch /etc/nginx/conf.d/outlets/server/30-offline-page.conf", "mkdir -p /etc/nginx/conf.d/outlets/discourse", "touch /etc/nginx/conf.d/outlets/discourse/20-https.conf", "touch /etc/nginx/conf.d/outlets/discourse/30-ratelimited.conf"]}
bootstrap failed with exit code 1
---
HINT: The plugin 'discourse-openid-connect' is now bundled with Discourse and should not be included in your container configuration.
Remove the line 'git clone https://github.com/discourse/discourse-openid-connect' from your containers/app.yml file, then try again.
For more information, see https://meta.discourse.org/t/373574
---
---
HINT: The plugin 'discourse-data-explorer' is now bundled with Discourse and should not be included in your container configuration.
Remove the line 'git clone https://github.com/discourse/discourse-data-explorer' from your containers/app.yml file, then try again.
For more information, see https://meta.discourse.org/t/373574
---
---
HINT: The plugin 'discourse-staff-notes' is now bundled with Discourse and should not be included in your container configuration.
Remove the line 'git clone https://github.com/discourse/discourse-staff-notes' from your containers/app.yml file, then try again.
For more information, see https://meta.discourse.org/t/373574
---
---
HINT: The plugin 'discourse-assign' is now bundled with Discourse and should not be included in your container configuration.
Remove the line 'git clone https://github.com/discourse/discourse-assign' from your containers/app.yml file, then try again.
For more information, see https://meta.discourse.org/t/373574
---
---
HINT: The plugin 'discourse-solved' is now bundled with Discourse and should not be included in your container configuration.
Remove the line 'git clone https://github.com/discourse/discourse-solved' from your containers/app.yml file, then try again.
For more information, see https://meta.discourse.org/t/373574
---
---
HINT: The plugin 'discourse-cakeday' is now bundled with Discourse and should not be included in your container configuration.
Remove the line 'git clone https://github.com/discourse/discourse-cakeday' from your containers/app.yml file, then try again.
For more information, see https://meta.discourse.org/t/373574
---
** FAILED TO BOOTSTRAP ** please scroll up and look for earlier error messages, there may be more than one.
./discourse-doctor may help diagnose the problem.

插件部分都很清楚——它们需要在 app.yaml 中注释掉。但这没有帮助——插件错误消失了,但是错误:

The "discourse" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version

仍然存在。

我对此无能为力。有没有办法将我的论坛更新到 2.8.14 版本?

如果没有,并且为了将来考虑,我如何从 2.8.5 版本升级到 3.x.x 版本?情况复杂化是因为我使用外部数据库 PostgreSQL。据我了解,由于新 Discourse 中的 AI 功能,它需要一个向量数据库 PgVector。我需要以某种方式迁移吗?是否有关于如何正确、无痛地完成此操作的指南?

我非常感谢您的帮助!

尝试更新 Docker。那或许会有帮助。如果不行,也许是这个?

─# docker version
Client: Docker Engine - Community
 Version:           28.1.1
 API version:       1.49
 Go version:        go1.23.8
 Git commit:        4eba377
 Built:             Fri Apr 18 09:52:18 2025
 OS/Arch:           linux/amd64
 Context:           default

Server: Docker Engine - Community
 Engine:
  Version:          28.1.1
  API version:      1.49 (minimum version 1.24)
  Go version:       go1.23.8
  Git commit:       01f442b
  Built:            Fri Apr 18 09:52:18 2025
  OS/Arch:          linux/amd64
  Experimental:     false
 containerd:
  Version:          1.7.27
  GitCommit:        05044ec0a9a75232cad458027ca83437aae3f4da
 runc:
  Version:          1.2.5
  GitCommit:        v1.2.5-0-g59923ef
 docker-init:
  Version:          0.19.0
  GitCommit:        de40ad0
└─# lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 20.04.6 LTS
Release:	20.04
Codename:	focal

我从 app.yaml 中删除了所有插件。这没有帮助:

FAILED
--------------------
Pups::ExecError: grep -q 'outlets/before-server' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The "before-server" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 ) failed with return #<Process::Status: pid 156 exit 1>
Location of failure: /usr/local/lib/ruby/gems/3.3.0/gems/pups-1.3.0/lib/pups/exec_command.rb:131:in `spawn'
exec failed with the params {"cmd"=>["cp $home/config/nginx.sample.conf /etc/nginx/conf.d/discourse.conf", "rm /etc/nginx/sites-enabled/default", "mkdir -p /var/nginx/cache", "grep -q 'outlets/before-server' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The \\"before-server\\" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 )", "grep -q 'outlets/server' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The \\"server\\" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 )", "grep -q 'outlets/discourse' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The \\"discourse\\" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 )", "mkdir -p /etc/nginx/conf.d/outlets/before-server", "touch /etc/nginx/conf.d/outlets/before-server/20-redirect-http-to-https.conf", "touch /etc/nginx/conf.d/outlets/before-server/30-ratelimited.conf", "mkdir -p /etc/nginx/conf.d/outlets/server", "touch /etc/nginx/conf.d/outlets/server/10-http.conf", "touch /etc/nginx/conf.d/outlets/server/20-https.conf", "touch /etc/nginx/conf.d/outlets/server/30-offline-page.conf", "mkdir -p /etc/nginx/conf.d/outlets/discourse", "touch /etc/nginx/conf.d/outlets/discourse/20-https.conf", "touch /etc/nginx/conf.d/outlets/discourse/30-ratelimited.conf"]}
bootstrap failed with exit code 1
** FAILED TO BOOTSTRAP ** please scroll up and look for earlier error messages, there may be more than one.
./discourse-doctor may help diagnose the problem.

请分享您的 app.yml 文件,但不要包含密码。

看起来插件不是导致重建失败的原因,问题出在这里。

您能提供日志中前面的上下文吗?也许实际的错误发生在那里。

This is full log:

└─# ./launcher rebuild app
x86_64 arch detected.
WARNING: containers/app.yml file is world-readable. You can secure this file by running: chmod o-rwx containers/app.yml
Ensuring launcher is up to date
Fetching origin
Launcher is up-to-date
Stopping old container
+ /usr/bin/docker stop -t 600 app
app
2.0.20251003-1437: Pulling from discourse/base
Digest: sha256:0db7c9b4598e2a1806658391669d791fd779aa4301fdfbed6a7f322bf64e66ab
Status: Image is up to date for discourse/base:2.0.20251003-1437
docker.io/discourse/base:2.0.20251003-1437
/usr/local/lib/ruby/gems/3.3.0/gems/pups-1.3.0/lib/pups.rb
/usr/local/bin/pups --stdin
I, [2025-11-20T12:57:18.105575 #1]  INFO -- : Reading from stdin
I, [2025-11-20T12:57:18.116863 #1]  INFO -- : File > /etc/service/redis/run  chmod: +x  chown:
I, [2025-11-20T12:57:18.120584 #1]  INFO -- : File > /etc/service/redis/log/run  chmod: +x  chown:
I, [2025-11-20T12:57:18.124261 #1]  INFO -- : File > /etc/runit/3.d/10-redis  chmod: +x  chown:
I, [2025-11-20T12:57:18.124872 #1]  INFO -- : Replacing daemonize yes with  in /etc/redis/redis.conf
I, [2025-11-20T12:57:18.126958 #1]  INFO -- : Replacing (?-mix:^pidfile.*$) with  in /etc/redis/redis.conf
I, [2025-11-20T12:57:18.127984 #1]  INFO -- : > install -d -m 0755 -o redis -g redis /shared/redis_data
I, [2025-11-20T12:57:18.131369 #1]  INFO -- :
I, [2025-11-20T12:57:18.131807 #1]  INFO -- : Replacing (?-mix:^logfile.*$) with logfile "" in /etc/redis/redis.conf
I, [2025-11-20T12:57:18.132422 #1]  INFO -- : Replacing (?-mix:^bind .*$) with  in /etc/redis/redis.conf
I, [2025-11-20T12:57:18.134285 #1]  INFO -- : Replacing (?-mix:^dir .*$) with dir /shared/redis_data in /etc/redis/redis.conf
I, [2025-11-20T12:57:18.135071 #1]  INFO -- : Replacing (?-mix:^protected-mode yes) with protected-mode no in /etc/redis/redis.conf
I, [2025-11-20T12:57:18.135730 #1]  INFO -- : Replacing # io-threads 4 with io-threads $redis_io_threads in /etc/redis/redis.conf
I, [2025-11-20T12:57:18.136429 #1]  INFO -- : > echo redis installed
I, [2025-11-20T12:57:18.138350 #1]  INFO -- : redis installed

I, [2025-11-20T12:57:18.138598 #1]  INFO -- : > cat /etc/redis/redis.conf | grep logfile
I, [2025-11-20T12:57:18.142582 #1]  INFO -- : logfile ""

I, [2025-11-20T12:57:18.142916 #1]  INFO -- : > exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf
I, [2025-11-20T12:57:18.144125 #1]  INFO -- : > sleep 10
18:C 20 Nov 2025 12:57:18.156 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
18:C 20 Nov 2025 12:57:18.156 # Redis version=7.0.15, bits=64, commit=00000000, modified=0, pid=18, just started
18:C 20 Nov 2025 12:57:18.156 # Configuration loaded
18:M 20 Nov 2025 12:57:18.157 * monotonic clock: POSIX clock_gettime
18:M 20 Nov 2025 12:57:18.158 * Running mode=standalone, port=6379.
18:M 20 Nov 2025 12:57:18.158 # Server initialized
18:M 20 Nov 2025 12:57:18.158 # WARNING Memory overcommit must be enabled! Without it, a background save or replication may fail under low memory condition. Being disabled, it can can also cause failures without low memory condition, see https://github.com/jemalloc/jemalloc/issues/1328. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
18:M 20 Nov 2025 12:57:18.158 * Loading RDB produced by version 7.0.15
18:M 20 Nov 2025 12:57:18.158 * RDB age 2960 seconds
18:M 20 Nov 2025 12:57:18.158 * RDB memory usage when created 6.02 Mb
18:M 20 Nov 2025 12:57:18.179 * Done loading RDB, keys loaded: 4596, keys expired: 9.
18:M 20 Nov 2025 12:57:18.179 * DB loaded from disk: 0.021 seconds
18:M 20 Nov 2025 12:57:18.179 * Ready to accept connections
I, [2025-11-20T12:57:28.146418 #1]  INFO -- :
I, [2025-11-20T12:57:28.147252 #1]  INFO -- : > thpoff echo "thpoff is installed!"
I, [2025-11-20T12:57:28.151019 #1]  INFO -- : thpoff is installed!

I, [2025-11-20T12:57:28.151452 #1]  INFO -- : > /usr/local/bin/ruby -e 'if ENV["DISCOURSE_SMTP_ADDRESS"] == "smtp.example.com"; puts "Aborting! Mail is not configured!"; exit 1; end'
I, [2025-11-20T12:57:28.258766 #1]  INFO -- :
I, [2025-11-20T12:57:28.258920 #1]  INFO -- : > /usr/local/bin/ruby -e 'if ENV["DISCOURSE_HOSTNAME"] == "discourse.example.com"; puts "Aborting! Domain is not configured!"; exit 1; end'
I, [2025-11-20T12:57:28.359414 #1]  INFO -- :
I, [2025-11-20T12:57:28.359546 #1]  INFO -- : > /usr/local/bin/ruby -e 'if (ENV["DISCOURSE_CDN_URL"] || "")[0..1] == "//"; puts "Aborting! CDN must have a protocol specified. Once fixed you should rebake your posts now to correct all posts."; exit 1; end'
I, [2025-11-20T12:57:28.465003 #1]  INFO -- :
I, [2025-11-20T12:57:28.465230 #1]  INFO -- : > rm -f /etc/cron.d/anacron
I, [2025-11-20T12:57:28.467452 #1]  INFO -- :
I, [2025-11-20T12:57:28.470130 #1]  INFO -- : File > /etc/cron.d/anacron  chmod:   chown:
I, [2025-11-20T12:57:28.474084 #1]  INFO -- : File > /etc/runit/1.d/copy-env  chmod: +x  chown:
I, [2025-11-20T12:57:28.478139 #1]  INFO -- : File > /etc/service/unicorn/run  chmod: +x  chown:
I, [2025-11-20T12:57:28.482090 #1]  INFO -- : File > /etc/service/nginx/run  chmod: +x  chown:
I, [2025-11-20T12:57:28.486062 #1]  INFO -- : File > /etc/runit/3.d/01-nginx  chmod: +x  chown:
I, [2025-11-20T12:57:28.489878 #1]  INFO -- : File > /etc/runit/3.d/02-unicorn  chmod: +x  chown:
I, [2025-11-20T12:57:28.497775 #1]  INFO -- : > cd /var/www/discourse && sudo -H -E -u discourse git clean -f
I, [2025-11-20T12:57:28.718382 #1]  INFO -- :
I, [2025-11-20T12:57:28.718551 #1]  INFO -- : > cd /var/www/discourse && sudo -H -E -u discourse bash -c '
  set -o errexit
  git fetch --tags --prune-tags --prune --force origin
  if [[ $(git symbolic-ref --short HEAD) == v2.8.5 ]] ; then
      git pull
  else
      git -c advice.detachedHead=false checkout v2.8.5
  fi
'
From https://github.com/discourse/discourse
 - [deleted]             (none)     -> origin/0-a-cakeday
 - [deleted]             (none)     -> origin/0-a-rubocop
 - [deleted]             (none)     -> origin/0-a-unused-services
 - [deleted]             (none)     -> origin/1-anon-nav
 - [deleted]             (none)     -> origin/add-auto-track-docs
 - [deleted]             (none)     -> origin/add-postoutletargs
 - [deleted]             (none)     -> origin/ai-summary-serializer
 - [deleted]             (none)     -> origin/ai-translation-configuration-update
 - [deleted]             (none)     -> origin/d-otp
 - [deleted]             (none)     -> origin/default-locale-temporarily-close-flag
 - [deleted]             (none)     -> origin/dependabot/bundler/rubocop-discourse-3.13.0
 - [deleted]             (none)     -> origin/dependabot/bundler/rubyzip-3.1.1
 - [deleted]             (none)     -> origin/dependabot/bundler/sass-a19c11c4e9
 - [deleted]             (none)     -> origin/dependabot/bundler/stripe-16.0.0
 - [deleted]             (none)     -> origin/dependabot/github_actions/actions/setup-node-5
 - [deleted]             (none)     -> origin/dependabot/npm_and_yarn/ember-cli-6.7.0
 - [deleted]             (none)     -> origin/dependabot/npm_and_yarn/embroider-f83e75fa89
 - [deleted]             (none)     -> origin/dependabot/npm_and_yarn/faker-js/faker-10.0.0
 - [deleted]             (none)     -> origin/dependabot/npm_and_yarn/glimmer/component-2.0.0
 - [deleted]             (none)     -> origin/dependabot/npm_and_yarn/lint-ed9b700cc1
 - [deleted]             (none)     -> origin/dependabot/npm_and_yarn/memfs-4.48.1
 - [deleted]             (none)     -> origin/dependabot/npm_and_yarn/webpack-5.102.0
 - [deleted]             (none)     -> origin/dev-merge-login-css
 - [deleted]             (none)     -> origin/dev/migrate-from-advanced-search-to-welcome-banner
 - [deleted]             (none)     -> origin/dev/no-more-array-clear
 - [deleted]             (none)     -> origin/dev/no-more-array-deprecations-post-stream
 - [deleted]             (none)     -> origin/dev/no-more-array-get-set
 - [deleted]             (none)     -> origin/dev/no-more-array-square-brackets-property
 - [deleted]             (none)     -> origin/exact-url-match-in-sidebar
 - [deleted]             (none)     -> origin/experimental-chat-search
 - [deleted]             (none)     -> origin/feat-add-ical-format-response-to-post-events-index
 - [deleted]             (none)     -> origin/feature/bump-wiki-docs-topics-op-edit
 - [deleted]             (none)     -> origin/feature/edit-theme-owned-palettes
 - [deleted]             (none)     -> origin/feature/split-categories-and-groups-for-moderators-setting
 - [deleted]             (none)     -> origin/feature/upcoming-changes-v1
 - [deleted]             (none)     -> origin/fix/deleted-user-email
 - [deleted]             (none)     -> origin/fix_debounce_in_d_multi_select
 - [deleted]             (none)     -> origin/fix_multiple_data_uploads
 - [deleted]             (none)     -> origin/headless-chrome
 - [deleted]             (none)     -> origin/issue/handle-worker-load-timeout-failure
 - [deleted]             (none)     -> origin/likes-dmenu
 - [deleted]             (none)     -> origin/llm-credit-allocation
 - [deleted]             (none)     -> origin/log_http_accept_language_header
 - [deleted]             (none)     -> origin/loic-pitchfork
 - [deleted]             (none)     -> origin/mt/only-skip-option
 - [deleted]             (none)     -> origin/mt/site_settings
 - [deleted]             (none)     -> origin/onebox-in-localized-posts
 - [deleted]             (none)     -> origin/pento/dev-calculate-flakyness
 - [deleted]             (none)     -> origin/photoswipe-lightbox
 - [deleted]             (none)     -> origin/remove-category-badge-recursive
 - [deleted]             (none)     -> origin/remove-footermessage-legacy-text
 - [deleted]             (none)     -> origin/simplify-add-remove-pm-user-group
 - [deleted]             (none)     -> origin/split-login-admin-settings
 - [deleted]             (none)     -> origin/system-email-fallback
 - [deleted]             (none)     -> origin/toggle_editor_when_unsupported
 - [deleted]             (none)     -> origin/topic-voting-ux
 - [deleted]             (none)     -> origin/type-package
 - [deleted]             (none)     -> origin/unicode-grant-admin
 - [deleted]             (none)     -> origin/update_pgvector_080
   5d239c560..51c218e3c  main                    -> origin/main
 * [new branch]          0-a-browser-testem      -> origin/0-a-browser-testem
 * [new branch]          0-a-card-border         -> origin/0-a-card-border
 * [new branch]          0-a-deps-categ          -> origin/0-a-deps-categ
 * [new branch]          0-a-floating-ui         -> origin/0-a-floating-ui
 * [new branch]          0-a-path                -> origin/0-a-path
   94faf7901..a58678538  a11y-post-heading-scrolling -> origin/a11y-post-heading-scrolling
 * [new branch]          adplugin-add-implement-impressions -> origin/adplugin-add-implement-impressions
 * [new branch]          ai-prototype/cascade-sheets -> origin/ai-prototype/cascade-sheets
 * [new branch]          ai-prototype/reaction-last -> origin/ai-prototype/reaction-last
 * [new branch]          anthropic-caching       -> origin/anthropic-caching
 + 5c183e735...ffaa66cd8 async_ember_helpers_patch -> origin/async_ember_helpers_patch  (forced update)
 * [new branch]          better-email-subject-lines -> origin/better-email-subject-lines
 * [new branch]          block-network-system    -> origin/block-network-system
 * [new branch]          blocks-system           -> origin/blocks-system
 * [new branch]          br/upload               -> origin/br/upload
 * [new branch]          browse-latest-topics-in-new-new-sub-tabs -> origin/browse-latest-topics-in-new-new-sub-tabs
 * [new branch]          btn-mixin-border-radius -> origin/btn-mixin-border-radius
 * [new branch]          cal-fix                 -> origin/cal-fix
 * [new branch]          calendar-fix            -> origin/calendar-fix
 * [new branch]          capybara_browser_checkts_control -> origin/capybara_browser_checkts_control
 * [new branch]          capybara_browser_checkts_experiment -> origin/capybara_browser_checkts_experiment
 * [new branch]          chat-banner-content     -> origin/chat-banner-content
 * [new branch]          composer-ios-hack       -> origin/composer-ios-hack
 * [new branch]          configure_pg_statement_timeout_for_unicorn_processes -> origin/configure_pg_statement_timeout_for_unicorn_processes
 * [new branch]          couple-sm-tweaks        -> origin/couple-sm-tweaks
 * [new branch]          custom_field            -> origin/custom_field
 * [new branch]          d-button-signature      -> origin/d-button-signature
 * [new branch]          d-menu-close-animation  -> origin/d-menu-close-animation
 * [new branch]          d-otp-followups         -> origin/d-otp-followups
 * [new branch]          dependabot/bundler/crack-1.0.1 -> origin/dependabot/bundler/crack-1.0.1
 * [new branch]          dependabot/bundler/excon-1.3.1 -> origin/dependabot/bundler/excon-1.3.1
 * [new branch]          dependabot/bundler/mail-2.9.0 -> origin/dependabot/bundler/mail-2.9.0
 * [new branch]          dependabot/bundler/rubyzip-3.2.2 -> origin/dependabot/bundler/rubyzip-3.2.2
 * [new branch]          dependabot/bundler/sass-95568ee139 -> origin/dependabot/bundler/sass-95568ee139
 * [new branch]          dependabot/bundler/stripe-18.0.0 -> origin/dependabot/bundler/stripe-18.0.0
 * [new branch]          dependabot/bundler/webmock-3.26.1 -> origin/dependabot/bundler/webmock-3.26.1
 * [new branch]          dependabot/bundler/zendesk_api-4.0.0.pre.1 -> origin/dependabot/bundler/zendesk_api-4.0.0.pre.1
 * [new branch]          dependabot/github_actions/actions/setup-node-6 -> origin/dependabot/github_actions/actions/setup-node-6
 * [new branch]          dependabot/npm_and_yarn/chart.js-4.5.1 -> origin/dependabot/npm_and_yarn/chart.js-4.5.1
 * [new branch]          dependabot/npm_and_yarn/embroider-b89ca3ee63 -> origin/dependabot/npm_and_yarn/embroider-b89ca3ee63
 * [new branch]          dependabot/npm_and_yarn/esbuild-0.27.0 -> origin/dependabot/npm_and_yarn/esbuild-0.27.0
 + c3027deb3...27fb7bbf0 dependabot/npm_and_yarn/fortawesome/fontawesome-free-7.1.0 -> origin/dependabot/npm_and_yarn/fortawesome/fontawesome-free-7.1.0  (forced update)
 * [new branch]          dependabot/npm_and_yarn/glob-13.0.0 -> origin/dependabot/npm_and_yarn/glob-13.0.0
 + 6b0686c06...c917fbfa3 dependabot/npm_and_yarn/jsuites-5.13.4 -> origin/dependabot/npm_and_yarn/jsuites-5.13.4  (forced update)
 * [new branch]          dependabot/npm_and_yarn/memfs-4.51.0 -> origin/dependabot/npm_and_yarn/memfs-4.51.0
 * [new branch]          dependabot/npm_and_yarn/morphlex-1.0.4 -> origin/dependabot/npm_and_yarn/morphlex-1.0.4
 * [new branch]          dependabot/npm_and_yarn/types-546d678181 -> origin/dependabot/npm_and_yarn/types-546d678181
 + 39ab10317...9a5504f09 dependabot/npm_and_yarn/uppy-573db43783 -> origin/dependabot/npm_and_yarn/uppy-573db43783  (forced update)
 * [new branch]          dev-add-autocomplete-results-signature-type -> origin/dev-add-autocomplete-results-signature-type
 * [new branch]          dev-allow-right-left-placements-for-autocomplete-menu -> origin/dev-allow-right-left-placements-for-autocomplete-menu
 * [new branch]          dev-azure-json-object   -> origin/dev-azure-json-object
 * [new branch]          dev-refactor-d-autocomplete -> origin/dev-refactor-d-autocomplete
 * [new branch]          dev-replace-hashtag-autocomplete-templates-with-components -> origin/dev-replace-hashtag-autocomplete-templates-with-components
   9d33c2629..6d7e3ce9f  dev/add-no-category-composer-site-setting -> origin/dev/add-no-category-composer-site-setting
 * [new branch]          dev/deprecate-nil-in-site-settings -> origin/dev/deprecate-nil-in-site-settings
 * [new branch]          dev/git-ignore-mise-local-conf -> origin/dev/git-ignore-mise-local-conf
 * [new branch]          dev/messagebus-response-headers -> origin/dev/messagebus-response-headers
 * [new branch]          dev/mt/discourse-category-moderation-groups -> origin/dev/mt/discourse-category-moderation-groups
 * [new branch]          dev/no-more-array-ember-methods -> origin/dev/no-more-array-ember-methods
 * [new branch]          dev/no-more-array-pushObject -> origin/dev/no-more-array-pushObject
 * [new branch]          dev/problem-check-cleanups-part-2 -> origin/dev/problem-check-cleanups-part-2
 + 6e00e4b6d...8898de768 dev/purge-widgets       -> origin/dev/purge-widgets  (forced update)
 * [new branch]          dev/remove-widgets-code -> origin/dev/remove-widgets-code
 + 50c30c39f...0d2c402dc dev/user-actions-reviewable-logging -> origin/dev/user-actions-reviewable-logging  (forced update)
 * [new branch]          disable-autofocus-otp-ios -> origin/disable-autofocus-otp-ios
 * [new branch]          discourse-id-error-logging -> origin/discourse-id-error-logging
 * [new branch]          discourse-id-update-support -> origin/discourse-id-update-support
 * [new branch]          dont_joins_categories_unnecessarily -> origin/dont_joins_categories_unnecessarily
 * [new branch]          dont_override_category_model -> origin/dont_override_category_model
 * [new branch]          easy-link-to-own-profile-from-user-card -> origin/easy-link-to-own-profile-from-user-card
 * [new branch]          ember_settled_check     -> origin/ember_settled_check
 + 64e725e17...030f51cfe ember_settled_experimental -> origin/ember_settled_experimental  (forced update)
 * [new branch]          feature/add-uploads-to-type-objects -> origin/feature/add-uploads-to-type-objects
 + c84648556...6fd7acf52 feature/assuming-iam-role-s3-pt2 -> origin/feature/assuming-iam-role-s3-pt2  (forced update)
   d3ae413fd..560d9e5f4  feature/chat-channel-sidebar-menu -> origin/feature/chat-channel-sidebar-menu
 * [new branch]          feature/copy-as-markdown -> origin/feature/copy-as-markdown
 * [new branch]          feature/github-mute-category-linkback -> origin/feature/github-mute-category-linkback
 * [new branch]          feature/requisite-site-settings -> origin/feature/requisite-site-settings
 * [new branch]          feature/upcoming-change-group-simplify -> origin/feature/upcoming-change-group-simplify
 * [new branch]          filter-uploads          -> origin/filter-uploads
 * [new branch]          fix-credit-allocation-resets -> origin/fix-credit-allocation-resets
 * [new branch]          fix-credit-error-popups -> origin/fix-credit-error-popups
 * [new branch]          fix-emoji-autocomplete-trigger-even-after-whitespace-in-term -> origin/fix-emoji-autocomplete-trigger-even-after-whitespace-in-term
 * [new branch]          fix-selector            -> origin/fix-selector
 * [new branch]          fix-translation-missing-in-email-templates -> origin/fix-translation-missing-in-email-templates
 * [new branch]          fix/ai-llm-status-check -> origin/fix/ai-llm-status-check
 * [new branch]          fix/calendar-missing-starts-at -> origin/fix/calendar-missing-starts-at
 * [new branch]          fix/deleted-posts-list-rendering -> origin/fix/deleted-posts-list-rendering
 * [new branch]          fix/notify-chat-user-non-channel-member -> origin/fix/notify-chat-user-non-channel-member
 + 9e18befeb...2f019fb59 form-kit-2-0            -> origin/form-kit-2-0  (forced update)
 + 01dabbed3...2d3a082cd horizon_as_default_for_new_sites -> origin/horizon_as_default_for_new_sites  (forced update)
 * [new branch]          image_grid_on_rte       -> origin/image_grid_on_rte
 * [new branch]          issue/draft-save-no-change -> origin/issue/draft-save-no-change
 * [new branch]          issue/fix-placeholder-rte-non-image-upload -> origin/issue/fix-placeholder-rte-non-image-upload
 * [new branch]          issue/quote-isolating   -> origin/issue/quote-isolating
 * [new branch]          jordan-feature          -> origin/jordan-feature
 + 40d18be01...99c6a3d14 keep-img-tag-implementation-for-excerpt-parser -> origin/keep-img-tag-implementation-for-excerpt-parser  (forced update)
   04ed87792..51c218e3c  latest                  -> origin/latest
 * [new branch]          likes-dmenu-mylikes     -> origin/likes-dmenu-mylikes
 * [new branch]          limit-post-voting       -> origin/limit-post-voting
 * [new branch]          linkbacks               -> origin/linkbacks
 * [new branch]          loc-title-edit          -> origin/loc-title-edit
 * [new branch]          localized-pg-headline   -> origin/localized-pg-headline
 * [new branch]          localized-search-data   -> origin/localized-search-data
 * [new branch]          log-max-sql-duration    -> origin/log-max-sql-duration
 + bd7c66753...b6a1847be loic-server-modifiers-types -> origin/loic-server-modifiers-types  (forced update)
 * [new branch]          loic/pagy               -> origin/loic/pagy
 * [new branch]          martin-brennan-patch-1  -> origin/martin-brennan-patch-1
 + e6bdecf7f...6f0670964 member-xp-1             -> origin/member-xp-1  (forced update)
 * [new branch]          modal-animation         -> origin/modal-animation
 + 483d30315...c1aa1fc97 mt/user_options         -> origin/mt/user_options  (forced update)
 * [new branch]          multipart-upload-fix    -> origin/multipart-upload-fix
   b38084846..3abbe3301  nat1-merge-branch       -> origin/nat1-merge-branch
 * [new branch]          no-silent-failure-invalid-regex-watched-words -> origin/no-silent-failure-invalid-regex-watched-words
 * [new branch]          one-step-wizard         -> origin/one-step-wizard
 * [new branch]          outlet-suspension-silenced -> origin/outlet-suspension-silenced
   3e69277e2..94af89fcf  peek-mode-v2            -> origin/peek-mode-v2
 * [new branch]          prevent-model-fails     -> origin/prevent-model-fails
 * [new branch]          problem-check-credit    -> origin/problem-check-credit
 * [new branch]          prototype-avatars       -> origin/prototype-avatars
 * [new branch]          qunit-binding           -> origin/qunit-binding
 * [new branch]          quote-button            -> origin/quote-button
 * [new branch]          quote-lightbox          -> origin/quote-lightbox
   99695c6c0..e9fb01e59  refactor-subgrid        -> origin/refactor-subgrid
 * [new branch]          release-infrastructure  -> origin/release-infrastructure
 * [new branch]          repo-refactor           -> origin/repo-refactor
 * [new branch]          revert                  -> origin/revert
 + 8a8148488...503758d99 rollup-plugin-experiment -> origin/rollup-plugin-experiment  (forced update)
 * [new branch]          rspec-color             -> origin/rspec-color
 + e8ccaeb1c...a3eccc73d sandbox/ai-team         -> origin/sandbox/ai-team  (forced update)
 + 1ef463255...007db3bd1 sandbox/dev-xp-1        -> origin/sandbox/dev-xp-1  (forced update)
   a925474ed..86f5bb772  sandbox/dev-xp-2        -> origin/sandbox/dev-xp-2
 + 3e69277e2...46a3d9ca5 sandbox/member-xp-1     -> origin/sandbox/member-xp-1  (forced update)
 + 1effbe0cc...915e24a0a sandbox/member-xp-2     -> origin/sandbox/member-xp-2  (forced update)
 + 170018e94...03b301782 sandbox/member-xp-3     -> origin/sandbox/member-xp-3  (forced update)
 + bfb813d85...883862176 sandbox/member-xp-4     -> origin/sandbox/member-xp-4  (forced update)
 + 4c42dfdae...ce93f2ec6 sandbox/staff-xp-1      -> origin/sandbox/staff-xp-1  (forced update)
 * [new branch]          screened-ip             -> origin/screened-ip
 * [new branch]          scripted_llm_tests      -> origin/scripted_llm_tests
 * [new branch]          search-localized        -> origin/search-localized
 * [new branch]          shared-edits            -> origin/shared-edits
 * [new branch]          show-topic-loading      -> origin/show-topic-loading
   beaacf9e0..47399adbd  stable                  -> origin/stable
 * [new branch]          test-runner-exp         -> origin/test-runner-exp
   04ed87792..51c218e3c  tests-passed            -> origin/tests-passed
 * [new branch]          tobiaseigen-patch-5     -> origin/tobiaseigen-patch-5
 * [new branch]          translation-retry-quota-rewrite -> origin/translation-retry-quota-rewrite
 * [new branch]          translations-from-crowdin-main -> origin/translations-from-crowdin-main
 * [new branch]          translations-from-crowdin-stable -> origin/translations-from-crowdin-stable
 * [new branch]          upgrade_rubocop_discourse -> origin/upgrade_rubocop_discourse
 * [new branch]          use-transcoded          -> origin/use-transcoded
 * [new branch]          use_pm_on_to_markdown   -> origin/use_pm_on_to_markdown
 * [new branch]          ux-ai-bot-sidebar-link  -> origin/ux-ai-bot-sidebar-link
 * [new branch]          ux-claimable-reivew-filter -> origin/ux-claimable-reivew-filter
 * [new branch]          ux-composer-mode-placeholder -> origin/ux-composer-mode-placeholder
 * [new branch]          ux-policy-button-width  -> origin/ux-policy-button-width
 * [new branch]          ux-sign-up-button-position -> origin/ux-sign-up-button-position
 * [new branch]          version-bump/main       -> origin/version-bump/main
 * [new branch]          version_bump/stable     -> origin/version_bump/stable
   c5bca775f..8d7db37c2  vite-squashed-rebased   -> origin/vite-squashed-rebased
 * [new branch]          white_space_paragraph_parsing -> origin/white_space_paragraph_parsing
 * [new branch]          x-amz-tagging           -> origin/x-amz-tagging
 t [tag update]          beta                    -> beta
 t [tag update]          latest-release          -> latest-release
 * [new tag]             v3.5.2                  -> v3.5.2
 * [new tag]             v3.6.0.beta2            -> v3.6.0.beta2
HEAD is now at 61cf79192 Version bump to v2.8.5 (#17187)
I, [2025-11-20T12:58:10.975801 #1]  INFO -- :
I, [2025-11-20T12:58:10.976348 #1]  INFO -- : > cd /var/www/discourse && sudo -H -E -u discourse git config user.discourse-version v2.8.5
I, [2025-11-20T12:58:10.990092 #1]  INFO -- :
I, [2025-11-20T12:58:10.990310 #1]  INFO -- : > cd /var/www/discourse && mkdir -p tmp
I, [2025-11-20T12:58:10.993582 #1]  INFO -- :
I, [2025-11-20T12:58:10.993719 #1]  INFO -- : > cd /var/www/discourse && chown discourse:www-data tmp
I, [2025-11-20T12:58:10.996441 #1]  INFO -- :
I, [2025-11-20T12:58:10.996632 #1]  INFO -- : > cd /var/www/discourse && mkdir -p tmp/pids
I, [2025-11-20T12:58:10.999355 #1]  INFO -- :
I, [2025-11-20T12:58:10.999470 #1]  INFO -- : > cd /var/www/discourse && mkdir -p tmp/sockets
I, [2025-11-20T12:58:11.002136 #1]  INFO -- :
I, [2025-11-20T12:58:11.002293 #1]  INFO -- : > cd /var/www/discourse && touch tmp/.gitkeep
I, [2025-11-20T12:58:11.004947 #1]  INFO -- :
I, [2025-11-20T12:58:11.005072 #1]  INFO -- : > cd /var/www/discourse && mkdir -p                    /shared/log/rails
I, [2025-11-20T12:58:11.007844 #1]  INFO -- :
I, [2025-11-20T12:58:11.007985 #1]  INFO -- : > cd /var/www/discourse && bash -c "touch -a           /shared/log/rails/{production,production_errors,unicorn.stdout,unicorn.stderr,sidekiq}.log"
I, [2025-11-20T12:58:11.012438 #1]  INFO -- :
I, [2025-11-20T12:58:11.012548 #1]  INFO -- : > cd /var/www/discourse && bash -c "ln    -s           /shared/log/rails/{production,production_errors,unicorn.stdout,unicorn.stderr,sidekiq}.log /var/www/discourse/log"
I, [2025-11-20T12:58:11.016830 #1]  INFO -- :
I, [2025-11-20T12:58:11.016924 #1]  INFO -- : > cd /var/www/discourse && bash -c "mkdir -p           /shared/{uploads,backups}"
I, [2025-11-20T12:58:11.021076 #1]  INFO -- :
I, [2025-11-20T12:58:11.021204 #1]  INFO -- : > cd /var/www/discourse && bash -c "ln    -s           /shared/{uploads,backups} /var/www/discourse/public"
I, [2025-11-20T12:58:11.025467 #1]  INFO -- :
I, [2025-11-20T12:58:11.025569 #1]  INFO -- : > cd /var/www/discourse && bash -c "mkdir -p           /shared/tmp/{backups,restores}"
I, [2025-11-20T12:58:11.029778 #1]  INFO -- :
I, [2025-11-20T12:58:11.029884 #1]  INFO -- : > cd /var/www/discourse && bash -c "ln    -s           /shared/tmp/{backups,restores} /var/www/discourse/tmp"
I, [2025-11-20T12:58:11.034102 #1]  INFO -- :
I, [2025-11-20T12:58:11.034224 #1]  INFO -- : > cd /var/www/discourse && chown -R discourse:www-data /shared/log/rails /shared/uploads /shared/backups /shared/tmp
I, [2025-11-20T12:58:11.069336 #1]  INFO -- :
I, [2025-11-20T12:58:11.069510 #1]  INFO -- : > cd /var/www/discourse && [ ! -d public/plugins ] || find public/plugins/ -maxdepth 1 -xtype l -delete
I, [2025-11-20T12:58:11.071978 #1]  INFO -- :
I, [2025-11-20T12:58:11.072492 #1]  INFO -- : Replacing # redis with sv start redis || exit 1 in /etc/service/unicorn/run
I, [2025-11-20T12:58:11.073877 #1]  INFO -- : > cp /var/www/discourse/config/nginx.sample.conf /etc/nginx/conf.d/discourse.conf
I, [2025-11-20T12:58:11.076755 #1]  INFO -- :
I, [2025-11-20T12:58:11.077000 #1]  INFO -- : > rm /etc/nginx/sites-enabled/default
I, [2025-11-20T12:58:11.079147 #1]  INFO -- :
I, [2025-11-20T12:58:11.079295 #1]  INFO -- : > mkdir -p /var/nginx/cache
I, [2025-11-20T12:58:11.081261 #1]  INFO -- :
I, [2025-11-20T12:58:11.081491 #1]  INFO -- : > grep -q 'outlets/before-server' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The "before-server" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 )
The "before-server" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.
I, [2025-11-20T12:58:11.085029 #1]  INFO -- :
I, [2025-11-20T12:58:11.086820 #1]  INFO -- : Terminating async processes
I, [2025-11-20T12:58:11.086912 #1]  INFO -- : Sending TERM to exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf pid: 18
18:signal-handler (1763643491) Received SIGTERM scheduling shutdown...
18:M 20 Nov 2025 12:58:11.133 # User requested shutdown...
18:M 20 Nov 2025 12:58:11.133 * Saving the final RDB snapshot before exiting.
18:M 20 Nov 2025 12:58:11.178 * DB saved on disk
18:M 20 Nov 2025 12:58:11.178 # Redis is now ready to exit, bye bye...


FAILED
--------------------
Pups::ExecError: grep -q 'outlets/before-server' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The "before-server" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 ) failed with return #<Process::Status: pid 156 exit 1>
Location of failure: /usr/local/lib/ruby/gems/3.3.0/gems/pups-1.3.0/lib/pups/exec_command.rb:131:in `spawn'
exec failed with the params {"cmd"=>["cp $home/config/nginx.sample.conf /etc/nginx/conf.d/discourse.conf", "rm /etc/nginx/sites-enabled/default", "mkdir -p /var/nginx/cache", "grep -q 'outlets/before-server' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The \"before-server\" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 )", "grep -q 'outlets/server' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The \"server\" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 )", "grep -q 'outlets/discourse' /etc/nginx/conf.d/discourse.conf || ( >&2 echo 'The \"discourse\" Nginx outlet is missing. This version of discourse_docker is not compatible with the chosen Discourse version.' ; exit 1 )", "mkdir -p /etc/nginx/conf.d/outlets/before-server", "touch /etc/nginx/conf.d/outlets/before-server/20-redirect-http-to-https.conf", "touch /etc/nginx/conf.d/outlets/before-server/30-ratelimited.conf", "mkdir -p /etc/nginx/conf.d/outlets/server", "touch /etc/nginx/conf.d/outlets/server/10-http.conf", "touch /etc/nginx/conf.d/outlets/server/20-https.conf", "touch /etc/nginx/conf.d/outlets/server/30-offline-page.conf", "mkdir -p /etc/nginx/conf.d/outlets/discourse", "touch /etc/nginx/conf.d/outlets/discourse/20-https.conf", "touch /etc/nginx/conf.d/outlets/discourse/30-ratelimited.conf"]}
bootstrap failed with exit code 1
** FAILED TO BOOTSTRAP ** please scroll up and look for earlier error messages, there may be more than one.
./discourse-doctor may help diagnose the problem.
66c43294171cf7dc0616baf53fdaf32130c9e09951dddbe01312c565deeb85db

很有可能您的操作系统也过时了。最简单和最安全的方法是迁移到一个安装了最新操作系统和 Docker 的新虚拟机上。

这是原始的 app.yml 文件。我对其进行了一些混淆处理。它包含了所有的插件。为进行测试,我将它们全部移除了,但重新构建仍然会产生错误。

app.yml (4.9 KB)

Ubuntu 20.04 仍然很好,并且拥有所有最新的软件包。
Docker Engine 28.1.1 也相当新。

如果我可以在当前虚拟机上就地更新,为什么还要迁移到另一个虚拟机?

请看我上面日志中的引用。

因为 PostgreSQL 升级可能会出现问题,而在新虚拟机上安装可以确保您的论坛不会出现故障。

但等等。您的 app.yml 中有这一行吗?由于当前的 Docker 容器无法与如此旧版本的 Discourse 配合使用,这行将不起作用。您需要升级到最新版本,或者至少是最新受支持的版本。

version: v2.8.10 ## CHANGED FROM stable (v2.8.5) TO v2.8.10 FOR UPDATE

此外,Discourse 不再支持在没有 HTTPS 的情况下运行,因此您需要取消注释 sslletsencrypt 模板。还有一些其他内容也已更改。我建议您使用 discourse-setup 进行完全重新安装,以获得最新的 app.yml

PostgreSQL 是在 Docker 中单独安装的,升级它没有问题。

这绝对是必要的吗?我暂时不想升级到 3.x.x 版本——它所有的 AI 功能都需要从 PostgreSQL 迁移到 PgVector。我们论坛实际上不需要 AI,而且我对 PgVector 一点也不熟悉,所以我不知道如何进行那样的迁移。所以,目前我更希望停留在最新的 2.8.x 版本——如果可能的话,是 2.8.14。
如果不行,那我当然不得不迁移。在我最初的消息中,我问过是否有关于此类迁移的指南?

但我不想使用 Discourse 的 HTTPS 和 letsencrypt。我的论坛位于 Nginx 后面,Nginx 是根据我们的边界规则配置的。我希望保留这种设置。

非常感谢您的帮助!期待您的评论。

我指出了几篇。恐怕没有一篇适用于您的设置。您将不得不升级 postgres。您将不得不安装 pgvector。

然后,由于您的安装与标准安装相去甚远,情况会比我描述的要复杂一些。

如果您有预算,可以到 Marketplace 咨询或直接联系我。

最新版本是 Discourse 3.6.0.beta3-latest。虽然没有什么是绝对不可能的,但如果您想停留在 2.8.x,那您还不如什么都不做。它不受支持,并且存在严重的安全问题。

2 个赞