homer icon indicating copy to clipboard operation
homer copied to clipboard

Homer on Raspibolt

Open Supersimmons opened this issue 1 year ago • 3 comments

Hello, i'm trying to install homer on my raspibolt node. I don't use Docker. Installation it's ok, but when i start homer for the first time with this command "npm run serve" in the homer directory (/home/homer/homer) i receive this error:

npm ERR! Missing script: "serve" npm ERR! npm ERR! To see a list of scripts, run: npm ERR! npm run

Thanks

Supersimmons avatar Sep 17 '22 10:09 Supersimmons

Hello @Supersimmons,

To run homer on the integrated node server, the command is npm run dev, for testing / development only. For production use, you can do a npm run build and serve the static html content from any webserver (nginx, apache, ...).

bastienwirtz avatar Sep 18 '22 14:09 bastienwirtz

Hello @bastienwirtz , following guide steps for raspibolt installation, i've to run this command to test starting Homer manually first to make sure it works. If i run your comman "npm run build" and then i start homer i receive error anyway

0 verbose cli /usr/bin/node /usr/bin/npm 1 info using [email protected] 2 info using [email protected] 3 timing npm:load:whichnode Completed in 0ms 4 timing config:load:defaults Completed in 15ms 5 timing config:load:file:/usr/lib/node_modules/npm/npmrc Completed in 2ms 6 timing config:load:builtin Completed in 2ms 7 timing config:load:cli Completed in 4ms 8 timing config:load:env Completed in 0ms 9 timing config:load:file:/home/homer/homer/.npmrc Completed in 0ms 10 timing config:load:project Completed in 2ms 11 timing config:load:file:/home/homer/.npmrc Completed in 0ms 12 timing config:load:user Completed in 1ms 13 timing config:load:file:/usr/etc/npmrc Completed in 0ms 14 timing config:load:global Completed in 1ms 15 timing config:load:validate Completed in 0ms 16 timing config:load:credentials Completed in 3ms 17 timing config:load:setEnvs Completed in 3ms 18 timing config:load Completed in 35ms 19 timing npm:load:configload Completed in 36ms 20 timing npm:load:mkdirpcache Completed in 3ms 21 timing npm:load:mkdirplogs Completed in 1ms 22 verbose title npm run serve 23 verbose argv "run" "serve" 24 timing npm:load:setTitle Completed in 4ms 25 timing config:load:flatten Completed in 9ms 26 timing npm:load:display Completed in 12ms 27 verbose logfile logs-max:10 dir:/home/homer/.npm/_logs 28 verbose logfile /home/homer/.npm/_logs/2022-09-18T19_29_26_848Z-debug-0.log 29 timing npm:load:logFile Completed in 15ms 30 timing npm:load:timers Completed in 0ms 31 timing npm:load:configScope Completed in 0ms 32 timing npm:load Completed in 73ms 33 silly logfile done cleaning log files 34 timing command:run Completed in 19ms 35 verbose stack Error: Missing script: "serve" 35 verbose stack 35 verbose stack To see a list of scripts, run: 35 verbose stack npm run 35 verbose stack at RunScript.run (/usr/lib/node_modules/npm/lib/commands/run-script.js:98:13) 35 verbose stack at async module.exports (/usr/lib/node_modules/npm/lib/cli.js:78:5) 36 verbose cwd /home/homer/homer 37 verbose Linux 5.15.61-v7l+ 38 verbose node v16.17.0 39 verbose npm v8.19.2 40 error Missing script: "serve"

Supersimmons avatar Sep 18 '22 19:09 Supersimmons

@Supersimmons This is expected, as there is no npm run serve command (there was at some point, that was the old name of the npm run dev command, it's the same thing). So, there is no "running homer" strictly speaking, the build command generates simple html static files which have to be hosted somewhere (behind a webserver)

bastienwirtz avatar Sep 18 '22 19:09 bastienwirtz