Laucher rebuild app fails

Hello, I spent some time searching for a solution to my problem, so I decided to post a request for help here. Any help would be greatly appreciated.
thank you.

My Discourse update failed when trying to rebuild using the sudo ./launcher rebuild app command.

here is the error :

FAILED
--------------------
Pups::ExecError: cd /var/www/discourse && su discourse -c 'bundle exec rake db:migrate' failed with return #<Process::Status: pid 612 exit 1>
Location of failure: /usr/local/lib/ruby/gems/3.3.0/gems/pups-1.2.1/lib/pups/exec_command.rb:132:in `spawn'
exec failed with the params {"cd"=>"$home", "tag"=>"migrate", "hook"=>"db_migrate", "cmd"=>["su discourse -c 'bundle exec rake db:migrate'"]}
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.

and here is the complete output.

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
remote: Enumerating objects: 98, done.
remote: Counting objects: 100% (98/98), done.
remote: Compressing objects: 100% (53/53), done.
remote: Total 98 (delta 44), reused 91 (delta 41), pack-reused 0 (from 0)
Unpacking objects: 100% (98/98), 33.85 KiB | 1.30 MiB/s, done.
From https://github.com/discourse/discourse_docker
   595dd6a..cfe8aa0  main               -> origin/main
 * [new branch]      clean-bundle-cache -> origin/clean-bundle-cache
 * [new branch]      launcher2-runtime  -> origin/launcher2-runtime
Updating Launcher...
Updating 595dd6a..cfe8aa0
Fast-forward
 .github/workflows/build.yml             |   8 +++++++-
 .github/workflows/launcher_go.yml       |  45 +++++++++++++++++++++++++++++++++++++++++++++
 image/base/install-nginx                |   2 ++
 image/base/install-oxipng               |   2 +-
 launcher_go/v2/cli_build.go             |  63 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++---
 launcher_go/v2/cli_build_test.go        | 132 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++------------
 launcher_go/v2/config/config.go         |  23 ++++++++++++-----------
 launcher_go/v2/docker/commands.go       |  48 +++++++++++++++++++++++++++++++++++-------------
 launcher_go/v2/main.go                  |   2 ++
 launcher_go/v2/test/containers/test.yml |   3 ++-
 10 files changed, 286 insertions(+), 42 deletions(-)
 create mode 100644 .github/workflows/launcher_go.yml
Launcher updated, restarting...
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.20240825-0027: Pulling from discourse/base
Digest: sha256:6de68cb49198b5281f79ed9401b3fe818c854d220dcf0238549fe2f2adb19146
Status: Image is up to date for discourse/base:2.0.20240825-0027
docker.io/discourse/base:2.0.20240825-0027
/usr/local/lib/ruby/gems/3.3.0/gems/pups-1.2.1/lib/pups.rb
/usr/local/bin/pups --stdin
I, [2024-08-30T06:56:18.948183 #1]  INFO -- : Reading from stdin
I, [2024-08-30T06:56:18.964205 #1]  INFO -- : File > /etc/service/postgres/run  chmod: +x  chown: 
I, [2024-08-30T06:56:18.968049 #1]  INFO -- : File > /etc/service/postgres/log/run  chmod: +x  chown: 
I, [2024-08-30T06:56:18.971804 #1]  INFO -- : File > /etc/runit/3.d/99-postgres  chmod: +x  chown: 
I, [2024-08-30T06:56:18.975928 #1]  INFO -- : File > /root/install_postgres  chmod: +x  chown: 
I, [2024-08-30T06:56:18.980242 #1]  INFO -- : File > /root/upgrade_postgres  chmod: +x  chown: 
I, [2024-08-30T06:56:18.981315 #1]  INFO -- : Replacing data_directory = '/var/lib/postgresql/13/main' with data_directory = '/shared/postgres_data' in /etc/postgresql/13/main/postgresql.conf
I, [2024-08-30T06:56:18.982464 #1]  INFO -- : Replacing (?-mix:#?listen_addresses *=.*) with listen_addresses = '*' in /etc/postgresql/13/main/postgresql.conf
I, [2024-08-30T06:56:18.983257 #1]  INFO -- : Replacing (?-mix:#?synchronous_commit *=.*) with synchronous_commit = $db_synchronous_commit in /etc/postgresql/13/main/postgresql.conf
I, [2024-08-30T06:56:18.983946 #1]  INFO -- : Replacing (?-mix:#?shared_buffers *=.*) with shared_buffers = $db_shared_buffers in /etc/postgresql/13/main/postgresql.conf
I, [2024-08-30T06:56:18.984609 #1]  INFO -- : Replacing (?-mix:#?work_mem *=.*) with work_mem = $db_work_mem in /etc/postgresql/13/main/postgresql.conf
I, [2024-08-30T06:56:18.985516 #1]  INFO -- : Replacing (?-mix:#?default_text_search_config *=.*) with default_text_search_config = '$db_default_text_search_config' in /etc/postgresql/13/main/postgresql.conf
I, [2024-08-30T06:56:18.986191 #1]  INFO -- : Replacing (?-mix:#?checkpoint_segments *=.*) with checkpoint_segments = $db_checkpoint_segments in /etc/postgresql/13/main/postgresql.conf
I, [2024-08-30T06:56:18.986778 #1]  INFO -- : Replacing (?-mix:#?logging_collector *=.*) with logging_collector = $db_logging_collector in /etc/postgresql/13/main/postgresql.conf
I, [2024-08-30T06:56:18.987367 #1]  INFO -- : Replacing (?-mix:#?log_min_duration_statement *=.*) with log_min_duration_statement = $db_log_min_duration_statement in /etc/postgresql/13/main/postgresql.conf
I, [2024-08-30T06:56:18.988402 #1]  INFO -- : Replacing (?-mix:^#local +replication +postgres +peer$) with local replication postgres  peer in /etc/postgresql/13/main/pg_hba.conf
I, [2024-08-30T06:56:18.988907 #1]  INFO -- : Replacing (?-mix:^host.*all.*all.*127.*$) with host all all 0.0.0.0/0 md5 in /etc/postgresql/13/main/pg_hba.conf
I, [2024-08-30T06:56:18.989381 #1]  INFO -- : Replacing (?-mix:^host.*all.*all.*::1\/128.*$) with host all all ::/0 md5 in /etc/postgresql/13/main/pg_hba.conf
I, [2024-08-30T06:56:18.989926 #1]  INFO -- : > if [ -f /root/install_postgres ]; then
  /root/install_postgres && rm -f /root/install_postgres
elif [ -e /shared/postgres_run/.s.PGSQL.5432 ]; then
  socat /dev/null UNIX-CONNECT:/shared/postgres_run/.s.PGSQL.5432 || exit 0 && echo postgres already running stop container ; exit 1
fi

I, [2024-08-30T06:56:20.337068 #1]  INFO -- : Generating locales (this might take a while)...
Generation complete.

I, [2024-08-30T06:56:20.337989 #1]  INFO -- : > HOME=/var/lib/postgresql USER=postgres exec chpst -u postgres:postgres:ssl-cert -U postgres:postgres:ssl-cert /usr/lib/postgresql/13/bin/postmaster -D /etc/postgresql/13/main
I, [2024-08-30T06:56:20.346153 #1]  INFO -- : File > /usr/local/bin/create_db  chmod: +x  chown: 
I, [2024-08-30T06:56:20.361384 #1]  INFO -- : File > /var/lib/postgresql/take-database-backup  chmod: +x  chown: postgres:postgres
I, [2024-08-30T06:56:20.368046 #1]  INFO -- : File > /var/spool/cron/crontabs/postgres  chmod:   chown: 
I, [2024-08-30T06:56:20.368835 #1]  INFO -- : > sleep 5
2024-08-30 06:56:20.427 UTC [36] LOG:  starting PostgreSQL 13.16 (Debian 13.16-1.pgdg120+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 12.2.0-14) 12.2.0, 64-bit
2024-08-30 06:56:20.427 UTC [36] LOG:  listening on IPv4 address "0.0.0.0", port 5432
2024-08-30 06:56:20.428 UTC [36] LOG:  listening on IPv6 address "::", port 5432
2024-08-30 06:56:20.431 UTC [36] LOG:  listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
2024-08-30 06:56:20.436 UTC [45] LOG:  database system was shut down at 2024-08-30 06:56:09 UTC
2024-08-30 06:56:20.444 UTC [36] LOG:  database system is ready to accept connections
I, [2024-08-30T06:56:25.374933 #1]  INFO -- : 
I, [2024-08-30T06:56:25.375218 #1]  INFO -- : > /usr/local/bin/create_db
2024-08-30 06:56:25.471 UTC [55] postgres@postgres ERROR:  database "discourse" already exists
2024-08-30 06:56:25.471 UTC [55] postgres@postgres STATEMENT:  CREATE DATABASE discourse;
createdb: error: database creation failed: ERROR:  database "discourse" already exists
2024-08-30 06:56:25.550 UTC [58] postgres@discourse ERROR:  role "discourse" already exists
2024-08-30 06:56:25.550 UTC [58] postgres@discourse STATEMENT:  create user discourse;
ERROR:  role "discourse" already exists
NOTICE:  extension "hstore" already exists, skipping
NOTICE:  extension "pg_trgm" already exists, skipping
NOTICE:  extension "vector" already exists, skipping
NOTICE:  version "0.7.4" of extension "vector" is already installed
NOTICE:  extension "hstore" already exists, skipping
NOTICE:  extension "pg_trgm" already exists, skipping
NOTICE:  extension "vector" already exists, skipping
NOTICE:  version "0.7.4" of extension "vector" is already installed
I, [2024-08-30T06:56:26.292454 #1]  INFO -- : GRANT
ALTER SCHEMA
CREATE EXTENSION
CREATE EXTENSION
CREATE EXTENSION
ALTER EXTENSION
CREATE EXTENSION
CREATE EXTENSION
CREATE EXTENSION
ALTER EXTENSION
UPDATE 0

I, [2024-08-30T06:56:26.293093 #1]  INFO -- : > echo postgres installed!
I, [2024-08-30T06:56:26.295550 #1]  INFO -- : postgres installed!

I, [2024-08-30T06:56:26.300606 #1]  INFO -- : File > /etc/service/redis/run  chmod: +x  chown: 
I, [2024-08-30T06:56:26.309609 #1]  INFO -- : File > /etc/service/redis/log/run  chmod: +x  chown: 
I, [2024-08-30T06:56:26.315683 #1]  INFO -- : File > /etc/runit/3.d/10-redis  chmod: +x  chown: 
I, [2024-08-30T06:56:26.316967 #1]  INFO -- : Replacing daemonize yes with  in /etc/redis/redis.conf
I, [2024-08-30T06:56:26.318451 #1]  INFO -- : Replacing (?-mix:^pidfile.*$) with  in /etc/redis/redis.conf
I, [2024-08-30T06:56:26.319623 #1]  INFO -- : > install -d -m 0755 -o redis -g redis /shared/redis_data
I, [2024-08-30T06:56:26.323067 #1]  INFO -- : 
I, [2024-08-30T06:56:26.323773 #1]  INFO -- : Replacing (?-mix:^logfile.*$) with logfile "" in /etc/redis/redis.conf
I, [2024-08-30T06:56:26.324542 #1]  INFO -- : Replacing (?-mix:^bind .*$) with  in /etc/redis/redis.conf
I, [2024-08-30T06:56:26.325226 #1]  INFO -- : Replacing (?-mix:^dir .*$) with dir /shared/redis_data in /etc/redis/redis.conf
I, [2024-08-30T06:56:26.326011 #1]  INFO -- : Replacing (?-mix:^protected-mode yes) with protected-mode no in /etc/redis/redis.conf
I, [2024-08-30T06:56:26.326740 #1]  INFO -- : Replacing # io-threads 4 with io-threads $redis_io_threads in /etc/redis/redis.conf
I, [2024-08-30T06:56:26.327389 #1]  INFO -- : > echo redis installed
I, [2024-08-30T06:56:26.330197 #1]  INFO -- : redis installed

I, [2024-08-30T06:56:26.330677 #1]  INFO -- : > cat /etc/redis/redis.conf | grep logfile
I, [2024-08-30T06:56:26.336165 #1]  INFO -- : logfile ""

I, [2024-08-30T06:56:26.336499 #1]  INFO -- : > exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf
I, [2024-08-30T06:56:26.337966 #1]  INFO -- : > sleep 10
104:C 30 Aug 2024 06:56:26.348 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
104:C 30 Aug 2024 06:56:26.348 # Redis version=7.0.7, bits=64, commit=00000000, modified=0, pid=104, just started
104:C 30 Aug 2024 06:56:26.348 # Configuration loaded
104:M 30 Aug 2024 06:56:26.349 * monotonic clock: POSIX clock_gettime
104:M 30 Aug 2024 06:56:26.349 * Running mode=standalone, port=6379.
104:M 30 Aug 2024 06:56:26.349 # Server initialized
104:M 30 Aug 2024 06:56:26.350 # 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.
104:M 30 Aug 2024 06:56:26.350 * Loading RDB produced by version 7.0.7
104:M 30 Aug 2024 06:56:26.350 * RDB age 17 seconds
104:M 30 Aug 2024 06:56:26.350 * RDB memory usage when created 3.73 Mb
104:M 30 Aug 2024 06:56:26.362 * Done loading RDB, keys loaded: 2858, keys expired: 0.
104:M 30 Aug 2024 06:56:26.362 * DB loaded from disk: 0.012 seconds
104:M 30 Aug 2024 06:56:26.362 * Ready to accept connections
I, [2024-08-30T06:56:36.342328 #1]  INFO -- : 
I, [2024-08-30T06:56:36.342654 #1]  INFO -- : > thpoff echo "thpoff is installed!"
I, [2024-08-30T06:56:36.348798 #1]  INFO -- : thpoff is installed!

I, [2024-08-30T06:56:36.349280 #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, [2024-08-30T06:56:36.454702 #1]  INFO -- : 
I, [2024-08-30T06:56:36.454873 #1]  INFO -- : > /usr/local/bin/ruby -e 'if ENV["DISCOURSE_HOSTNAME"] == "discourse.example.com"; puts "Aborting! Domain is not configured!"; exit 1; end'
I, [2024-08-30T06:56:36.556018 #1]  INFO -- : 
I, [2024-08-30T06:56:36.556202 #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, [2024-08-30T06:56:36.657888 #1]  INFO -- : 
I, [2024-08-30T06:56:36.658084 #1]  INFO -- : > rm -f /etc/cron.d/anacron
I, [2024-08-30T06:56:36.660378 #1]  INFO -- : 
I, [2024-08-30T06:56:36.662911 #1]  INFO -- : File > /etc/cron.d/anacron  chmod:   chown: 
I, [2024-08-30T06:56:36.668033 #1]  INFO -- : File > /etc/runit/1.d/copy-env  chmod: +x  chown: 
I, [2024-08-30T06:56:36.672293 #1]  INFO -- : File > /etc/service/unicorn/run  chmod: +x  chown: 
I, [2024-08-30T06:56:36.676557 #1]  INFO -- : File > /etc/service/nginx/run  chmod: +x  chown: 
I, [2024-08-30T06:56:36.680699 #1]  INFO -- : File > /etc/runit/3.d/01-nginx  chmod: +x  chown: 
I, [2024-08-30T06:56:36.684848 #1]  INFO -- : File > /etc/runit/3.d/02-unicorn  chmod: +x  chown: 
I, [2024-08-30T06:56:36.684970 #1]  INFO -- : Replacing # postgres with if [ -f /root/install_postgres ]; then
  /root/install_postgres
  rm /root/install_postgres
fi
sv start postgres || exit 1
 in /etc/service/unicorn/run
I, [2024-08-30T06:56:36.686390 #1]  INFO -- : > cd /var/www/discourse && sudo -H -E -u discourse git reset --hard
Updating files: 100% (34680/34680), done.
I, [2024-08-30T06:56:40.963927 #1]  INFO -- : HEAD is now at 274e18622 FIX: Video uploads sometimes hang indefinitely (#28523)

I, [2024-08-30T06:56:40.964459 #1]  INFO -- : > cd /var/www/discourse && sudo -H -E -u discourse git clean -f
I, [2024-08-30T06:56:41.127206 #1]  INFO -- : 
I, [2024-08-30T06:56:41.128273 #1]  INFO -- : > cd /var/www/discourse && sudo -H -E -u discourse bash -c '
  set -o errexit
  if [ $(git rev-parse --is-shallow-repository) == "true" ]; then
      git remote set-branches --add origin main
      git remote set-branches origin tests-passed
      git fetch --depth 1 origin tests-passed
  else
      git fetch --tags --prune-tags --prune --force origin
  fi
'
From https://github.com/discourse/discourse
 - [deleted]             (none)     -> origin/0-a-gjs-ace
 - [deleted]             (none)     -> origin/better-respect-End-key-in-topics
 - [deleted]             (none)     -> origin/dependabot/npm_and_yarn/ember-cli-deprecation-workflow-3.0.2
 - [deleted]             (none)     -> origin/dependabot/npm_and_yarn/ember/test-helpers-4.0.1
 - [deleted]             (none)     -> origin/dependabot/npm_and_yarn/eslint-9.7.0
 - [deleted]             (none)     -> origin/feature/site-text-result-selected-lang
 - [deleted]             (none)     -> origin/fix/add-user-to-user-directory-when-activated
 - [deleted]             (none)     -> origin/issue/fix-bookmark-clearing-reminder
 - [deleted]             (none)     -> origin/native-class-components-2
 - [deleted]             (none)     -> origin/native-class-components-3
 - [deleted]             (none)     -> origin/notifications_id_bigint
 - [deleted]             (none)     -> origin/prevent-desktop-notifications-on-mobile
 - [deleted]             (none)     -> origin/ux/admin-plugins-ui-guidelines
   274e18622..361e954c5  main                    -> origin/main
 * [new branch]          add-ability-to-watch-chat-threads -> origin/add-ability-to-watch-chat-threads
   3729ac14c..0fafa0bb4  category-experts-approved-webhook-event -> origin/category-experts-approved-webhook-event
 * [new branch]          class-initializer       -> origin/class-initializer
 * [new branch]          dependabot/bundler/ruby-readability-0.7.2 -> origin/dependabot/bundler/ruby-readability-0.7.2
 * [new branch]          dependabot/npm_and_yarn/ace-builds-1.36.1 -> origin/dependabot/npm_and_yarn/ace-builds-1.36.1
 * [new branch]          dependabot/npm_and_yarn/babel-fcd205ed66 -> origin/dependabot/npm_and_yarn/babel-fcd205ed66
 * [new branch]          dependabot/npm_and_yarn/puppeteer-core-23.2.1 -> origin/dependabot/npm_and_yarn/puppeteer-core-23.2.1
 * [new branch]          dev-make-user-1-1-with-user-password -> origin/dev-make-user-1-1-with-user-password
 * [new branch]          dev/glimmer-post-menu   -> origin/dev/glimmer-post-menu
 * [new branch]          dev/port-outlet-wrapper-to-stable -> origin/dev/port-outlet-wrapper-to-stable
 * [new branch]          dev/remove-deprecated-respect-plugin-positional-argument -> origin/dev/remove-deprecated-respect-plugin-positional-argument
 * [new branch]          drop-old-notification-id-columns -> origin/drop-old-notification-id-columns
 * [new branch]          ember-native-class      -> origin/ember-native-class
 * [new branch]          feature/add-user-to-topic_tags_changed-event -> origin/feature/add-user-to-topic_tags_changed-event
 * [new branch]          feature/support-multiple-moderation-groups-on-category -> origin/feature/support-multiple-moderation-groups-on-category
 * [new branch]          fix-bookmarks-filtering -> origin/fix-bookmarks-filtering
 * [new branch]          fix/check-existing-custom-flags-before-creation -> origin/fix/check-existing-custom-flags-before-creation
 * [new branch]          login-buttons-multiple-class -> origin/login-buttons-multiple-class
 + a25ac32bc...97bd38cf4 mt/converter            -> origin/mt/converter  (forced update)
   d3ad2ecda..15f036baf  stable                  -> origin/stable
   274e18622..361e954c5  tests-passed            -> origin/tests-passed
 * [new branch]          translations-from-crowdin-stable -> origin/translations-from-crowdin-stable
 * [new branch]          unique-tag-user-notification -> origin/unique-tag-user-notification
 * [new branch]          ux-1pw-ignore           -> origin/ux-1pw-ignore
 * [new branch]          ux/convert-chat-plugin-ui -> origin/ux/convert-chat-plugin-ui
 * [new branch]          ux_form_template_flash  -> origin/ux_form_template_flash
 t [tag update]          beta                    -> beta
 t [tag update]          latest-release          -> latest-release
 * [new tag]             v3.3.1                  -> v3.3.1
 * [new tag]             v3.4.0.beta1            -> v3.4.0.beta1
I, [2024-08-30T06:56:42.073269 #1]  INFO -- : 
I, [2024-08-30T06:56:42.073714 #1]  INFO -- : > cd /var/www/discourse && sudo -H -E -u discourse bash -c '
  set -o errexit
  if [[ $(git symbolic-ref --short HEAD) == tests-passed ]] ; then
      git pull
  else
      git -c advice.detachedHead=false checkout tests-passed
  fi
'
Switched to a new branch 'tests-passed'
I, [2024-08-30T06:56:44.851651 #1]  INFO -- : branch 'tests-passed' set up to track 'origin/tests-passed'.

I, [2024-08-30T06:56:44.852217 #1]  INFO -- : > cd /var/www/discourse && sudo -H -E -u discourse git config user.discourse-version tests-passed
I, [2024-08-30T06:56:44.865672 #1]  INFO -- : 
I, [2024-08-30T06:56:44.865986 #1]  INFO -- : > cd /var/www/discourse && mkdir -p tmp
I, [2024-08-30T06:56:44.868951 #1]  INFO -- : 
I, [2024-08-30T06:56:44.869247 #1]  INFO -- : > cd /var/www/discourse && chown discourse:www-data tmp
I, [2024-08-30T06:56:44.872276 #1]  INFO -- : 
I, [2024-08-30T06:56:44.872501 #1]  INFO -- : > cd /var/www/discourse && mkdir -p tmp/pids
I, [2024-08-30T06:56:44.875816 #1]  INFO -- : 
I, [2024-08-30T06:56:44.876029 #1]  INFO -- : > cd /var/www/discourse && mkdir -p tmp/sockets
I, [2024-08-30T06:56:44.879320 #1]  INFO -- : 
I, [2024-08-30T06:56:44.879578 #1]  INFO -- : > cd /var/www/discourse && touch tmp/.gitkeep
I, [2024-08-30T06:56:44.882918 #1]  INFO -- : 
I, [2024-08-30T06:56:44.883194 #1]  INFO -- : > cd /var/www/discourse && mkdir -p                    /shared/log/rails
I, [2024-08-30T06:56:44.886219 #1]  INFO -- : 
I, [2024-08-30T06:56:44.886447 #1]  INFO -- : > cd /var/www/discourse && bash -c "touch -a           /shared/log/rails/{production,production_errors,unicorn.stdout,unicorn.stderr,sidekiq}.log"
I, [2024-08-30T06:56:44.890808 #1]  INFO -- : 
I, [2024-08-30T06:56:44.891103 #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, [2024-08-30T06:56:44.895797 #1]  INFO -- : 
I, [2024-08-30T06:56:44.896013 #1]  INFO -- : > cd /var/www/discourse && bash -c "mkdir -p           /shared/{uploads,backups}"
I, [2024-08-30T06:56:44.900610 #1]  INFO -- : 
I, [2024-08-30T06:56:44.901011 #1]  INFO -- : > cd /var/www/discourse && bash -c "ln    -s           /shared/{uploads,backups} /var/www/discourse/public"
I, [2024-08-30T06:56:44.905409 #1]  INFO -- : 
I, [2024-08-30T06:56:44.905624 #1]  INFO -- : > cd /var/www/discourse && bash -c "mkdir -p           /shared/tmp/{backups,restores}"
I, [2024-08-30T06:56:44.910429 #1]  INFO -- : 
I, [2024-08-30T06:56:44.910686 #1]  INFO -- : > cd /var/www/discourse && bash -c "ln    -s           /shared/tmp/{backups,restores} /var/www/discourse/tmp"
I, [2024-08-30T06:56:44.915057 #1]  INFO -- : 
I, [2024-08-30T06:56:44.915356 #1]  INFO -- : > cd /var/www/discourse && chown -R discourse:www-data /shared/log/rails /shared/uploads /shared/backups /shared/tmp
I, [2024-08-30T06:56:44.938455 #1]  INFO -- : 
I, [2024-08-30T06:56:44.938891 #1]  INFO -- : > cd /var/www/discourse && [ ! -d public/plugins ] || find public/plugins/ -maxdepth 1 -xtype l -delete
I, [2024-08-30T06:56:44.941762 #1]  INFO -- : 
I, [2024-08-30T06:56:44.942235 #1]  INFO -- : Replacing # redis with sv start redis || exit 1 in /etc/service/unicorn/run
I, [2024-08-30T06:56:44.942951 #1]  INFO -- : > cd /var/www/discourse/plugins && git clone https://github.com/discourse/docker_manager.git
Cloning into 'docker_manager'...
I, [2024-08-30T06:56:45.959336 #1]  INFO -- : 
I, [2024-08-30T06:56:45.959554 #1]  INFO -- : > cd /var/www/discourse/plugins && git clone https://github.com/discourse/discourse-calendar
Cloning into 'discourse-calendar'...
I, [2024-08-30T06:56:46.979465 #1]  INFO -- : 
I, [2024-08-30T06:56:46.979867 #1]  INFO -- : > cd /var/www/discourse/plugins && git clone https://github.com/paviliondev/discourse-events
Cloning into 'discourse-events'...
I, [2024-08-30T06:56:47.680698 #1]  INFO -- : 
I, [2024-08-30T06:56:47.681126 #1]  INFO -- : > cd /var/www/discourse/plugins && git clone https://github.com/xomads/discourse-video-upload
Cloning into 'discourse-video-upload'...
I, [2024-08-30T06:56:48.323561 #1]  INFO -- : 
I, [2024-08-30T06:56:48.324134 #1]  INFO -- : > cp /var/www/discourse/config/nginx.sample.conf /etc/nginx/conf.d/discourse.conf
I, [2024-08-30T06:56:48.328453 #1]  INFO -- : 
I, [2024-08-30T06:56:48.329067 #1]  INFO -- : > rm /etc/nginx/sites-enabled/default
I, [2024-08-30T06:56:48.331726 #1]  INFO -- : 
I, [2024-08-30T06:56:48.332230 #1]  INFO -- : > mkdir -p /var/nginx/cache
I, [2024-08-30T06:56:48.335070 #1]  INFO -- : 
I, [2024-08-30T06:56:48.335953 #1]  INFO -- : Replacing pid /run/nginx.pid; with daemon off; in /etc/nginx/nginx.conf
I, [2024-08-30T06:56:48.336609 #1]  INFO -- : Replacing (?m-ix:upstream[^\}]+\}) with upstream discourse { server 127.0.0.1:3000; } in /etc/nginx/conf.d/discourse.conf
I, [2024-08-30T06:56:48.337166 #1]  INFO -- : Replacing (?-mix:server_name.+$) with server_name _ ; in /etc/nginx/conf.d/discourse.conf
I, [2024-08-30T06:56:48.337686 #1]  INFO -- : Replacing (?-mix:client_max_body_size.+$) with client_max_body_size $upload_size ; in /etc/nginx/conf.d/discourse.conf
I, [2024-08-30T06:56:48.338218 #1]  INFO -- : Replacing (?-mix:worker_connections.+$) with worker_connections $nginx_worker_connections ; in /etc/nginx/nginx.conf
I, [2024-08-30T06:56:48.338673 #1]  INFO -- : > echo "done configuring web"
I, [2024-08-30T06:56:48.340760 #1]  INFO -- : done configuring web

I, [2024-08-30T06:56:48.341186 #1]  INFO -- : > cd /var/www/discourse && gem install bundler --conservative -v $(awk '/BUNDLED WITH/ { getline; gsub(/ /,""); print $0 }' Gemfile.lock)
I, [2024-08-30T06:56:48.663785 #1]  INFO -- : 
I, [2024-08-30T06:56:48.663958 #1]  INFO -- : > cd /var/www/discourse && find /var/www/discourse ! -user discourse -exec chown discourse {} \+
I, [2024-08-30T06:56:50.010467 #1]  INFO -- : 
I, [2024-08-30T06:56:50.010985 #1]  INFO -- : > cd /var/www/discourse && if [ "tests-passed" != "tests-passed" ]; then
  rm -rf app/assets/javascripts/node_modules
fi
I, [2024-08-30T06:56:50.012899 #1]  INFO -- : 
I, [2024-08-30T06:56:50.013108 #1]  INFO -- : > cd /var/www/discourse && su discourse -c 'yarn config set network-timeout 60000 -g'
I, [2024-08-30T06:56:50.386384 #1]  INFO -- : yarn config v1.22.22
success Set "network-timeout" to "60000".
Done in 0.08s.

I, [2024-08-30T06:56:50.386945 #1]  INFO -- : > cd /var/www/discourse && su discourse -c 'yarn install --frozen-lockfile && yarn cache clean'
warning Resolution field "unset-value@2.0.1" is incompatible with requested version "unset-value@^1.0.0"
warning " > @discourse/lint-configs@1.3.9" has incorrect peer dependency "ember-template-lint@6.0.0".
warning " > @glint/environment-ember-loose@1.4.0" has unmet peer dependency "@glimmer/component@^1.1.2".
warning " > discourse-markdown-it@1.0.0" has unmet peer dependency "xss@*".
warning "workspace-aggregator-f15441dd-2a2f-4d3b-8279-019453a69d41 > discourse > @uppy/aws-s3@3.0.6" has incorrect peer dependency "@uppy/core@^3.1.2".
warning "workspace-aggregator-f15441dd-2a2f-4d3b-8279-019453a69d41 > discourse > @uppy/aws-s3-multipart@3.1.3" has incorrect peer dependency "@uppy/core@^3.1.2".
warning "workspace-aggregator-f15441dd-2a2f-4d3b-8279-019453a69d41 > discourse > @uppy/xhr-upload@3.1.1" has incorrect peer dependency "@uppy/core@^3.1.2".
warning "workspace-aggregator-f15441dd-2a2f-4d3b-8279-019453a69d41 > discourse-plugins > ember-this-fallback@0.4.0" has unmet peer dependency "ember-source@^3.28.11 || ^4.0.0".
warning "workspace-aggregator-f15441dd-2a2f-4d3b-8279-019453a69d41 > admin > ember-source > router_js@8.0.3" has unmet peer dependency "rsvp@^4.8.5".
warning "workspace-aggregator-f15441dd-2a2f-4d3b-8279-019453a69d41 > discourse > @uppy/aws-s3 > @uppy/xhr-upload@3.3.0" has incorrect peer dependency "@uppy/core@^3.2.1".
I, [2024-08-30T06:59:00.836576 #1]  INFO -- : yarn install v1.22.22
[1/5] Validating package.json...
[2/5] Resolving packages...
[3/5] Fetching packages...
[4/5] Linking dependencies...
[5/5] Building fresh packages...
$ ./app/assets/javascripts/run-patch-package && rm -rf app/assets/javascripts/node_modules
patch-package 8.0.0
Applying patches...
babel-plugin-debug-macros@0.3.4 ✔
content-tag@2.0.1 ✔
decorator-transforms@2.0.0 ✔
ember-this-fallback@0.4.0 (1 deprecation-name) ✔
ember-this-fallback@0.4.0 (2 themes) ✔
ember-this-fallback@0.4.0 (3 exclude-strict-mode) ✔
virtual-dom@2.1.1 ✔
Done in 121.86s.
yarn cache v1.22.22
success Cleared cache.
Done in 7.97s.

I, [2024-08-30T06:59:00.838203 #1]  INFO -- : > cd /var/www/discourse && su discourse -c 'bundle install --jobs $(($(nproc) - 1)) --retry 3'
I, [2024-08-30T06:59:08.967237 #1]  INFO -- : Fetching gem metadata from https://rubygems.org/........
Fetching net-imap 0.4.15
Installing net-imap 0.4.15
Fetching css_parser 1.19.0
Installing css_parser 1.19.0
Fetching uri 0.13.1
Installing uri 0.13.1
Fetching faraday-net_http 3.3.0
Installing faraday-net_http 3.3.0
Fetching faraday 2.11.0
Installing faraday 2.11.0
Fetching google-protobuf 4.28.0 (x86_64-linux)
Installing google-protobuf 4.28.0 (x86_64-linux)
Fetching highline 3.1.1
Installing highline 3.1.1
Fetching thor 1.3.2
Installing thor 1.3.2
Fetching omniauth-oauth 1.2.1
Installing omniauth-oauth 1.2.1
Bundle complete! 142 Gemfile dependencies, 184 gems now installed.
Gems in the groups 'test' and 'development' were not installed.
Bundled gems are installed into `./vendor/bundle`
1 installed gem you directly depend on is looking for funding.
  Run `bundle fund` for details

I, [2024-08-30T06:59:08.967865 #1]  INFO -- : > cd /var/www/discourse && su discourse -c 'LOAD_PLUGINS=0 bundle exec rake plugin:pull_compatible_all'
I, [2024-08-30T06:59:13.800474 #1]  INFO -- : discourse-calendar is already at latest compatible version
discourse-events is already at latest compatible version
discourse-video-upload is already at latest compatible version
docker_manager is already at latest compatible version

I, [2024-08-30T06:59:13.801181 #1]  INFO -- : > exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf
I, [2024-08-30T06:59:13.803288 #1]  INFO -- : > sleep 10
608:C 30 Aug 2024 06:59:13.823 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
608:C 30 Aug 2024 06:59:13.823 # Redis version=7.0.7, bits=64, commit=00000000, modified=0, pid=608, just started
608:C 30 Aug 2024 06:59:13.823 # Configuration loaded
608:M 30 Aug 2024 06:59:13.824 * monotonic clock: POSIX clock_gettime
608:M 30 Aug 2024 06:59:13.824 # Warning: Could not create server TCP listening socket *:6379: bind: Address already in use
608:M 30 Aug 2024 06:59:13.824 # Failed listening on port 6379 (TCP), aborting.
I, [2024-08-30T06:59:23.807920 #1]  INFO -- : 
I, [2024-08-30T06:59:23.808747 #1]  INFO -- : > cd /var/www/discourse && su discourse -c 'bundle exec rake db:migrate'
rake aborted!
[DiscourseVideoUpload] Javascript files under `assets/javascripts` are automatically included in JS bundles.
Manual register_asset calls should be removed. (attempted to add javascripts/lib/vimeo-upload.js)
/var/www/discourse/lib/plugin/instance.rb:717:in `register_asset'
/var/www/discourse/plugins/discourse-video-upload/plugin.rb:13:in `activate!'
/var/www/discourse/lib/plugin/instance.rb:778:in `instance_eval'
/var/www/discourse/lib/plugin/instance.rb:778:in `activate!'
/var/www/discourse/lib/discourse.rb:348:in `block in activate_plugins!'
/var/www/discourse/lib/discourse.rb:345:in `each'
/var/www/discourse/lib/discourse.rb:345:in `activate_plugins!'
/var/www/discourse/config/application.rb:232:in `block in <class:Application>'
/var/www/discourse/lib/plugin.rb:6:in `initialization_guard'
/var/www/discourse/config/application.rb:232:in `<class:Application>'
/var/www/discourse/config/application.rb:75:in `<module:Discourse>'
/var/www/discourse/config/application.rb:74:in `<top (required)>'
/var/www/discourse/Rakefile:7:in `<top (required)>'
/var/www/discourse/vendor/bundle/ruby/3.3.0/gems/rake-13.2.1/exe/rake:27:in `<top (required)>'
/usr/local/bin/bundle:25:in `load'
/usr/local/bin/bundle:25:in `<main>'
(See full trace by running task with --trace)
I, [2024-08-30T06:59:55.564695 #1]  INFO -- : gem install uuidtools -v 2.2.0 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Successfully installed uuidtools-2.2.0
1 gem installed
gem install iso-639 -v 0.3.5 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Successfully installed iso-639-0.3.5
1 gem installed
gem install ice_cube -v 0.16.4 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Successfully installed ice_cube-0.16.4
1 gem installed
gem install icalendar -v 2.8.0 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
ActiveSupport is required for TimeWithZone support, but not required for general use.
Successfully installed icalendar-2.8.0
1 gem installed
gem install icalendar-recurrence -v 1.1.3 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Successfully installed icalendar-recurrence-1.1.3
1 gem installed
gem install date -v 3.3.4 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Building native extensions. This could take a while...
Successfully installed date-3.3.4
1 gem installed
gem install time -v 0.2.0 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Successfully installed time-0.2.0
1 gem installed
gem install stringio -v 3.1.1 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Building native extensions. This could take a while...
Successfully installed stringio-3.1.1
1 gem installed
gem install omnievent -v 0.1.0.pre3 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Successfully installed omnievent-0.1.0.pre3
1 gem installed
gem install omnievent-icalendar -v 0.1.0.pre5 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Successfully installed omnievent-icalendar-0.1.0.pre5
1 gem installed
gem install omnievent-api -v 0.1.0.pre2 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Successfully installed omnievent-api-0.1.0.pre2
1 gem installed
gem install omnievent-eventbrite -v 0.1.0.pre2 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Successfully installed omnievent-eventbrite-0.1.0.pre2
1 gem installed
gem install omnievent-eventzilla -v 0.1.0.pre2 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Successfully installed omnievent-eventzilla-0.1.0.pre2
1 gem installed
gem install omnievent-meetup -v 0.1.0.pre1 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Successfully installed omnievent-meetup-0.1.0.pre1
1 gem installed
gem install omnievent-outlook -v 0.1.0.pre2 -i /var/www/discourse/plugins/discourse-events/gems/3.3.4 --no-document --ignore-dependencies --no-user-install
Successfully installed omnievent-outlook-0.1.0.pre2
1 gem installed

I, [2024-08-30T06:59:55.565538 #1]  INFO -- : Terminating async processes
I, [2024-08-30T06:59:55.565618 #1]  INFO -- : Sending INT to HOME=/var/lib/postgresql USER=postgres exec chpst -u postgres:postgres:ssl-cert -U postgres:postgres:ssl-cert /usr/lib/postgresql/13/bin/postmaster -D /etc/postgresql/13/main pid: 36
I, [2024-08-30T06:59:55.565721 #1]  INFO -- : Sending TERM to exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf pid: 104
104:signal-handler (1725001195) Received SIGTERM scheduling shutdown...
2024-08-30 06:59:55.566 UTC [36] LOG:  received fast shutdown request
2024-08-30 06:59:55.568 UTC [36] LOG:  aborting any active transactions
2024-08-30 06:59:55.572 UTC [36] LOG:  background worker "logical replication launcher" (PID 51) exited with exit code 1
2024-08-30 06:59:55.578 UTC [46] LOG:  shutting down
104:M 30 Aug 2024 06:59:55.599 # User requested shutdown...
104:M 30 Aug 2024 06:59:55.599 * Saving the final RDB snapshot before exiting.
2024-08-30 06:59:55.612 UTC [36] LOG:  database system is shut down
104:M 30 Aug 2024 06:59:55.622 * DB saved on disk
104:M 30 Aug 2024 06:59:55.622 # Redis is now ready to exit, bye bye...


FAILED
--------------------
Pups::ExecError: cd /var/www/discourse && su discourse -c 'bundle exec rake db:migrate' failed with return #<Process::Status: pid 612 exit 1>
Location of failure: /usr/local/lib/ruby/gems/3.3.0/gems/pups-1.2.1/lib/pups/exec_command.rb:132:in `spawn'
exec failed with the params {"cd"=>"$home", "tag"=>"migrate", "hook"=>"db_migrate", "cmd"=>["su discourse -c 'bundle exec rake db:migrate'"]}
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.
df03c3401b35e1722e269363f40677ac73227c543d2bac52730700a30795f531

No I don’t think it’s that. Why do you say that @pinder99 ?

It’s DiscourseVideoUpload, remove that plugin.

You can see from the log it has issues.

I don’t see any issues in the log related to events.

4 Likes

I have disabled the DiscourseVideoUpload plugin as suggested and the upgrade did complete successfully. My site is back thank you.

2 Likes