업데이트가 사용 가능하다는 알림을 받은 후, 평소처럼 웹 인터페이스에 접속하여 업데이트 버튼을 눌렀습니다.
전형적인 discourse 스타일대로, 설치 환경이 스스로 파괴되어 다시 이미지를 빌드해서 실행하는 것이 불가능한 상태입니다.
저는 데이터 이미지와 웹 이미지를 분리하여 모두 docker를 통해 실행하고 있습니다.
평소 이 문제를 해결하던 수동 재빌드 스크립트는 다음과 같습니다:
./launcher bootstrap discourse-web && ./launcher destroy discourse-web && ./launcher start discourse-web
이 명령을 실행하면 다음과 같은 오류가 발생합니다:
I, [2025-02-05T01:12:54.160568 #1] INFO -- : > cd /var/www/discourse && gem install bundler --conservative -v $(awk '/BUNDLED WITH/ { getline; gsub(/ /,""); print $0 }' Gemfile.lock)
I, [2025-02-05T01:12:55.503875 #1] INFO -- : Successfully installed bundler-2.5.18
1 gem installed
I, [2025-02-05T01:12:55.503987 #1] INFO -- : > cd /var/www/discourse && find /var/www/discourse ! -user discourse -exec chown discourse {} \+
I, [2025-02-05T01:12:56.681293 #1] INFO -- :
I, [2025-02-05T01:12:56.681583 #1] INFO -- : > cd /var/www/discourse && if [ "beta" != "tests-passed" ]; then
rm -rf app/assets/javascripts/node_modules
fi
I, [2025-02-05T01:12:56.685171 #1] INFO -- :
I, [2025-02-05T01:12:56.685238 #1] INFO -- : > cd /var/www/discourse && su discourse -c 'yarn install --frozen-lockfile && yarn cache clean'
error discourse@: The engine "yarn" is incompatible with this module. Expected version "please-use-pnpm". Got "1.22.19"
warning discourse@: The engine "pnpm" appears to be invalid.
error Found incompatible module.
I, [2025-02-05T01:12:57.086009 #1] INFO -- : yarn install v1.22.19
info No lockfile found.
[1/5] Validating package.json...
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
FAILED
--------------------
Pups::ExecError: cd /var/www/discourse && su discourse -c 'yarn install --frozen-lockfile && yarn cache clean' failed with return #<Process::Status: pid 202 exit 1>
Location of failure: /usr/local/lib/ruby/gems/3.2.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 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.
./discourse-doctor may help diagnose the problem.
d480e23784a1dd765d52d483ee94174d7d5cfad5ba8ccec61e76a48ac8ddf32a
이 오류에 대한 매칭되는 정보를 찾지 못하고 있으며, discourse-base 이미지를 초기화하거나 pull하는 것조차 아무런 차이를 만들지 않습니다 - 모든 것이 여기서 죽습니다.
다시 시스템을 정상적으로 실행 상태로 돌릴 수 있는 방법이 있을까요?