This document is organized into two major sections: for general upkeep, and then secondly, to diagnose and solve problems with the webui.
When installing from Docker or unRAID, updates are accomplished through their respective utilities, e.g.,
docker pull or the unRAID UI. For FreeBSD, follow the instructions on the FreeBSD installation page. For all other deployments, follow these steps:
# cd /usr/games/minecraft # git fetch # git pull origin master # npm install --unsafe-perm
Be sure to look out for any errors produced to the screen from
npm install–unfixed errors with modules (e.g.,
userid) will leave the webui in an unusable state.
Finally, restart the webui process. This differs on installation-to-installation, but can be accomplished in the following ways, listed in descending preferential order:
# supervisorctl restart mineos # used on MineOS Turnkey, and all install-on-distro deployments
# service mineos restart # used by
3) reboot the server
Resetting the webui is different than updating–but is also not frequently needed. If you are manually changing any of the source code, or simply want to carpet-bomb to the repo to its base state, follow these steps:
# cd /usr/games/minecraft # git fetch # git reset --hard origin/master # git checkout master # rm -rf ./node_modules # npm install --unsafe-perm
Once again, be sure to restart the wbui process to ensure that all the reset scripts and node modules are active and loaded.
In cases where there are any node module installation failures, the webui may show templating text, e.g.,
CURRENTLY_SELECTED_SERVER, and the like. Though the positioning may be correct, it is also not showing any of the servers, load averages, or even the logged-in username.
These problems are always preceeded by error output in
This issue is caused by the omission of
# npm install > email@example.com install /usr/games/minecraft/node_modules/posix > node-gyp rebuild sh: 1: node-gyp: Permission denied npm ERR! file sh npm ERR! code ELIFECYCLE npm ERR! errno ENOENT npm ERR! syscall spawn npm ERR! firstname.lastname@example.org install: `node-gyp rebuild` npm ERR! spawn ENOENT npm ERR! npm ERR! Failed at the email@example.com install script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
This issue is caused by a
node installation that is unsupported–that is, the version of node invoked is not compatible with some of the
npm dependencies and critical packages did not build.
# npm install posix --unsafe-perm firstname.lastname@example.org install /usr/games/minecraft/node_modules/posix node-gyp rebuild make: Entering directory ‘/usr/games/minecraft/node_modules/posix/build’ CXX(target) Release/obj.target/posix/src/posix.o In file included from …/node_modules/nan/nan.h:190, from …/src/posix.cc:1: …/node_modules/nan/nan_maybe_43_inl.h: In function ‘Nan::Maybe Nan::ForceSet(v8::Localv8::Object, v8::Localv8::Value, v8::Localv8::Value, v8::PropertyAttribute)’: …/node_modules/nan/nan_maybe_43_inl.h:88:15: error: ‘class v8::Object’ has no member named ‘ForceSet’ return obj->ForceSet(GetCurrentContext(), key, value, attribs); [snip] gyp ERR! build error gyp ERR! stack Error: make failed with exit code: 2 gyp ERR! stack at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:258:23) gyp ERR! stack at ChildProcess.emit (events.js:182:13) gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:235:12) gyp ERR! System Linux 4.16.8-1-ARCH gyp ERR! command “/usr/bin/node” “/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js” “rebuild” gyp ERR! cwd /usr/games/minecraft/node_modules/posix gyp ERR! node -v v4.0.0 gyp ERR! node-gyp -v v3.6.2 gyp ERR! not ok npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! email@example.com install: node-gyp rebuild npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the firstname.lastname@example.org install 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/2018-05-11T03_17_31_779Z-debug.log
In this case, identify your version of node (
node -v); either remove and install a more recent version, or change the init file to point to your preferred binary.
# which node /usr/bin/node # node -v v8.17.0
In the event you have multiple versions of node present, you will want to update the init files in your
# cat /etc/supervisor/conf.d/mineos.conf [program:mineos] command=/usr/bin/node webui.js ...