Ok, corretto come da Stuck on yarn install, Time out.
Per riferimento, in /var/discourse/templates/web.template.yml ho aggiunto questo blocco:
- exec:
cd: $home
cmd:
- su discourse -c 'yarn config set network-timeout 600000 -g'
prima che venga chiamato questo:
- exec:
cd: $home
hook: yarn
cmd:
- |-
if [ "$version" != "tests-passed" ]; then
rm -rf app/assets/javascripts/node_modules
fi
- su discourse -c 'yarn install --frozen-lockfile && yarn cache clean'
Ma perché va in timeout? La soluzione nell’argomento collegato afferma che è a causa delle scarse specifiche del server (istanza Google e2.micro, 2 core, 1 GB di RAM). Ma questo è un VPS con 4 core e 6 GB.