npm run build not working as "dist" directory doesn't exists
As I tried to install a production version of sepia, I got this error:
$npm run build
> peertube-search-index@0.0.1 build /var/www/peertube-search-index
> rm -r dist && tsc && cp -r themes dist/ && cd ./client && npm run build
rm: impossible de supprimer 'dist': Aucun fichier ou dossier de ce type
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! peertube-search-index@0.0.1 build: `rm -r dist && tsc && cp -r themes dist/ && cd ./client && npm run build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the peertube-search-index@0.0.1 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2021-08-12T15_06_12_275Z-debug.log
It appears that it fails because the "dist" directory doesn't exists. Creating this directory resolve the error.