Giter VIP home page Giter VIP logo

nixos's Introduction

nixos

This repository contains my configuration for my Nixos systems. I don't provide any garantuees that it will work on other systems. In addition some of the scripts required for installation will destroy your data when used.

Originally forked from https://git.2li.ch/Nebucatnetzer/nixos

VM installation

This allows you to setup a VM with minimal effort. However this requires some prerequisites.

  • A VM running the minimal NixOS ISO reachable with SSH under [email protected].
  • The VM runs UEFI.
  • You've set a password for the nixos user.
  1. ./scripts/install_new_vm.xsh
  2. Provide the required information and wait until the script is finished.
  3. Reboot and profit!

Creating fresh development VMs

TODO: add example CLI command to create VMs using qm

  1. Create a new VM in Proxmox (use UEFI instead if BIOS). The VM will have its hostname set to nixos and will be available within local network under the domain name of nixos.home.kyrych.uk.
  2. Create a new system under systems directory.
  3. Open the vm's console in Proxmox and set a password for the nixos user. This is needed for
  4. Run ./scripts/install_over_ssh.sh. If this script fails with WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!, run ssh-keygen -R nixos.home.kyrych.uk and retry.

Creating an LXC container with NixOS

Currently not working

  1. Run this on proxmox node:
pct create $(pvesh get /cluster/nextid) \
  local:vztmpl/nixos-22.05-default_188886451_x86_64.tar.xz \
  --description nixos-template \
  --hostname nixos-template \
  --arch amd64 \
  --ostype unmanaged \
  --cores 2 \
  --net0 name=eth0,ip=dhcp,bridge=vmbr0,firewall=1 \
  --storage local-zfs \
  --cmode console \
  --features nesting=1 \
  --unprivileged true \
  --template true

Hardware installation

  1. curl -L https://github.com/dmytrokyrychuk/nixos/archive/refs/heads/main.tar.gz | tar xz && mv nixos-main nixos
  2. cd nixos && nix-shell
  3. sudo python3 scripts/format-disk.py
  4. sudo nixos-install --no-root-passwd --root /mnt --impure --flake .#SYSTEMNAME

Update remote systems

Simply run the script scripts/update_all_systems.xsh and it will iterate over all defined systems. The script requires Xonsh but can be easily adapted to BASH or similar.

Non-Nixos System

  1. scripts/install-home-manager.sh

nixos's People

Contributors

nebucatnetzer avatar dmytrokyrychuk avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.