-
Notifications
You must be signed in to change notification settings - Fork 160
Spinning up a new custom cluster
Jean-Baptiste Giraudeau edited this page Oct 14, 2020
·
6 revisions
First checkout cardano-ops, from there:
cp globals-shelley-dev.nix globals-<my env>.nix
ln -s globals-<my env>.nix globals.nix
cp topologies/shelley-dev.nix topologies/<my env>.nix
Then customize globals-<my env>.nix
(at least environmentName
to match <my env>
) and topology/<my env>.nix
as needed.
run
nix-shell
which will provides the correct environnement for deployment and also cardano-cli bash completion.
create-shelley-genesis-and-keys
./scripts/create-aws.sh
First enable libvirtd for you system. On NixOS:
{ pkgs, lib, ... }:
{
virtualisation.libvirtd.enable = true;
systemd.services.libvirtd.restartIfChanged = lib.mkForce true;
networking.firewall.checkReversePath = false;
environment.systemPackages = with pkgs; [ virtmanager ];
}
Check that the default pool is available. Under root
user:
# virsh pool-list
Name State Autostart
-------------------------------------------
default active yes
If default
pool is not setup yet, run under root
:
# virsh pool-define /dev/stdin <<EOF
<pool type='dir'>
<name>default</name>
<target>
<path>/var/lib/libvirt/images</path>
</target>
</pool>
EOF
# virsh pool-start default
# virsh pool-autostart default
Then:
./scripts/create-libvirtd.sh
After that, using the nixops deploy
command directly is enough (cf. https://nixos.org/nixops/manual/).