Table of Contents
edit /etc/nix/nix.conf
to include the following:
experimental-features = nix-command flakes
optionally (but strongly suggested because it will dramatically speed up first-build times), also add these lines to nix.conf
in order to enable the Holochain binary caches.
public keys can be checked at the substituter URLs.
substituters = https://cache.nixos.org/ https://cache.holo.host/ https://holochain-ci.cachix.org trusted-public-keys = cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= cache.holo.host-1:lNXIXtJgS9Iuw4Cu6X0HINLu9sTfcjEntnrgwMQIMcE= cache.holo.host-2:ZJCkX3AUYZ8soxTLfTb60g+F3MkWD7hkH9y8CgqwhDQ= holochain-ci.cachix.org-1:5IUSkZc0aoRS53rfkvH9Kid40NpyjwCMCzwRTXy+QN8=
prequisite: follow 'Nix setup' above.
# enter dev shell (we need impure because Holonix is not pure 😢)
$ nix develop --impure
[<...>]$ npm install
[<...>]$ npm run hc:build
[<...>]$ npm run hc:pack
[<...>]$ npm run fe:build
[<...>]$ npm run hc:mk-sensemaker # this may take a while to run
# in dev shell
[<...>]$ npm run hc:run
# in another dev shell
[<...>]$ miniserve .
# any static server will work, e.g. any of these: https://gist.github.com/willurd/5720255
# in yet another dev shell
[<...>]$ xdg-open http://localhost:8080/index.html
# alternately, just go there in your browser
# perform above build steps
npm run hc:clean
# terminal 1
hc sandbox -f=9000 generate happs/paperz -r=9999 network mdns
# terminal 2
hc sandbox -f=9008 generate happs/paperz -r=9998 network mdns
# terminal 3
miniserve -p 8081 .
# terminal 4
miniserve -p 8082 .
now browse & change ports (at bottom of page):
-
-
app: 9999
-
admin: 9009
-
-
-
app: 9998
-
admin: 9008
-
then refresh the pages.