Problemen met het updaten van een 10 jaar oude site

Hmmm. I think I’m hitting a similar issue. Running a now 10 year old (!) Discourse instance that’s never been migrated and has been updated consistently inconsistently :slight_smile:

Tried updating Docker Manager via the Dashboard today and am now getting this in browser console when trying to render the Admin settings (specifically, the Customize link generated by the “try disabling some frontend components” message):

loader.js:247 Uncaught (in promise) Error: Could not find module `discourse/lib/decorators` imported from `discourse/plugins/docker_manager/discourse/routes/update`

Getting a PUPS error when trying to rebuild on the CLI:

FAILED
--------------------
Pups::ExecError: cd /var/www/discourse && su discourse -c 'yarn config set network-timeout 60000 -g' failed with return #<Process::Status: pid 280 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", "hook"=>"yarn", "cmd"=>["if [ \"$version\" != \"tests-passed\" ]; then\n  rm -rf app/assets/javascripts/node_modules\nfi", "su discourse -c 'yarn config set network-timeout 60000 -g'", "su discourse -c 'yarn install --frozen-lockfile && yarn cache clean'"]}
bootstrap failed with exit code 1
** FAILED TO BOOTSTRAP ** please scroll up and look for earlier error messages, there may be more than one.

There are no other apparent errors in the bootstrap. This is a single-container install… any ideas for how I get unstuck? The site is currently still up but in a pretty bad state.

Oh wacht, de PUPS-fout komt misschien hierdoor:

error This project's package.json defines "packageManager": "yarn@pnpm@9.15.5". However the current global version of Yarn is 1.22.22.

Hoe dan ook…

Heb je je probleem uiteindelijk kunnen oplossen? Het herstellen van een back-up naar een nieuwe server is hier waarschijnlijk ook de beste oplossing, in plaats van te worstelen met een verouderde installatie.

Figured it out, actually! We’d cherrypicked a commit a year ago to deal with something broken in main, and the Docker update manager plugin did not like that (it must not have had a check for a detached git head), which broke the deploy. Just doing a git reset –hard && ./launcher rebuild app on the server fixed it in the end, but it was very confusing in the meantime :slight_smile:

4 likes