nixos-polarflake

NixOS :snowflake: Configuration dedicated to computer science learning

https://github.com/altaks/nixos-polarflake

Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (11.5%) to scientific vocabulary

Keywords

automation config flake flakes linux nix nixos rice script
Last synced: 4 months ago · JSON representation ·

Repository

NixOS :snowflake: Configuration dedicated to computer science learning

Basic Info
  • Host: GitHub
  • Owner: Altaks
  • License: mit
  • Language: Nix
  • Default Branch: main
  • Homepage:
  • Size: 1.52 MB
Statistics
  • Stars: 4
  • Watchers: 2
  • Forks: 0
  • Open Issues: 5
  • Releases: 0
Topics
automation config flake flakes linux nix nixos rice script
Created 12 months ago · Last pushed 6 months ago
Metadata Files
Readme Funding License Code of conduct Citation Codeowners Security

README.md

:snowflake: Polarflake

Polarflake is a NixOS configuration dedicated to computer learning. This configuration was created specifically for the IUT in La Rochelle, France.

It provides all the tools, software, services and systems needed to follow the FullStack Developer course without missing a single tool.

The aim of this NixOS configuration is to provide new students with a Linux configuration that is quick and easy to install, so that they are ready for the next three years.

Why NixOS ?

NixOS is an operating system based on the Nix package manager, it provides a way for a user to describe it's system's configuration declarativly and avoid long hours of diving into obscure linux commands to copy a Linux configuration from one computer to another

More information about this here : :snowflake: Nix & NixOS :snowflake:

Configuration contents

This NixOS configuration provides to following content to the user's system :

  • :hammerandwrench: Programming tools for C, C++, Java, JavaScript, TypeScript, Flutter/Dart, Rust, Swift, Python, associated debugging tools & Jetbrains IDEs
  • :chartwithupwards_trend: Math related tools (Scilab, Geogebra 6, ZeGrapher)
  • :toolbox: SysAdmin utilities (compression, Network sniffers, partitions managers, SSH clients, Taskfiles, Justfiles, Git, GitHub CLI, etc...)
  • :paintbrush: Developer UI/UX software (Figma, GIMP, Krita)
  • :rocket: Bootloader configuration (GRUB 2, Grub themes, Encrypted partitions support)
  • :space_invader: Nerd fonts
  • :shield: Network, Firewall configuration, Linux Hotspot
  • :electric_plug: Virtualization systems (Docker, Podman, VirtualBox, Vagrant, Libvirtd)
  • :desktop_computer: Gnome configuration w/ extensions
  • :floppy_disk: Terminal config & utils (OhMyPosh, FZF, Fastfetch & zoxide)
  • :bustinsilhouette: Team work tools (Teams, Slack, Discord, etc...)

[!TIP] This configuration is set to apply the :fr: fr_FR configuration both for the keyboard & the system's language. You can change it in the modules/locales.nix file before installing the configuration.

[!WARNING] The base configuration is installed by default if you do not provide any profile argument whilst starting the installation script. The base configuration does not provide any hardware related driver (e.g. GPU). For those who want their graphic driver to be installed right away, please refer to the following profiles list :

Nvidia
AMD
Dedicated GPU
Dedicated GPU Integrated GPU
Stable
nvidia-stable Work in progress Radeon amd-stable
Legacy driver (470) nvidia-legacy-470 Southern Island amd-legacy-si-cik
Legacy driver (390) nvidia-legacy-390 Sea Island amd-legacy-si-cik
Legacy driver (340) nvidia-legacy-340

Nvidia users can refer to the following registry : https://www.nvidia.com/en-us/drivers/unix/legacy-gpu/ to determine whether or not their GPU is considered legacy by Nvidia

AMD gpu users can refer to the following links : https://en.wikipedia.org/wiki/RadeonHD8000series , https://en.wikipedia.org/wiki/RadeonHD7000series to determine their GPU category name

Installation

To install this configuration, you first need to install NixOS yourself

After that, you will need Git to clone the configuration easily. You can temporarily install it using the following command : sh nix-shell -p git

Then, within the freshly created shell, start installing this configuration by cloning the configuration files :

```sh

Clone the configuration on your machine

git clone https://github.com/Altaks/NixOS-polarflake ```

After cloning the configuration, you only need to execute these commands :

```sh

Warp into the configuration folder

cd NixOS-polarflake

Install the configuration

This will ask for sudo mode access.

Base profile installation

./install.sh

OR

Specific profile installation, example :

/install.sh nvidia-stable => Installs the nvidia stable profile

./install.sh ```

[!CAUTION] Use Ctrl + C to cancel the installation then reboot to avoid any nix-store deadlocks. If you stopped the script during the generation build/switch phase, you might encounter bugs/crashes/corrupted files.

Once the script ends, you've installed the configuration, the last thing you need to do is to reboot your system, using the sudo reboot now command or the UI.

Upon rebooting your system, make sure your new first boot entry in your BIOS/UEFI is set on NixOS boot (which corresponds to GRUB) and not Linux Boot Manager (which corresponds to system-boot, the default installed bootloader which won't boot onto the right configuration)

[!IMPORTANT]

Updates :

Once you've installed the configuration, you won't get updates without re-executing the ./install.sh script. The system will create a new generation providing newer versions of the software and use them instead of the previously installed versions.

If you want the updated version of this configuration and not only the software within it, simply git pull in this folder and you'll be able to fetch the new configuration if there's any new content

Removing previous generations :

During a system rebuild, NixOS keeps the old configuration in a generation, that stays on your PC until you tell the OS to remove the fallback generations. These generation take up a lot of storage capacity, because there are copies/duplicates of the same software libraries etc...

You can earn your storage back in four different ways :

  • The main way is using the sudo nix-collect-garbage command that will delete every generation except the current one. (Source)

  • The next most used way is to use the nix-store --optimise -v command, which will create internal symlinks in the /nix/store folder, that stores every software installed on your system. It removes duplicates and keeps only one instance of a software version. (Source)

  • Modifying this project configuration.nix and adding the following nix.optimise.automatic = true; which will make NixOS optimize the Nix store during uptime. Then reinstall the configuration and reboot. (Source)

[!IMPORTANT]

Using backups

This installation scripts generates backups of generations between switches, to avoid the pain of changing something and it wrecks the whole configuration. In case you've changed something in the configuration and failed to reinstall it, you can reinstall a backup using the following method :

Backup of the system configuration : ```sh

Warp into the system root folder

cd /

Clear the NixOS configuration folder before installing the backup

sudo rm -rf /etc/nixos/

Extracting the configuration backup, since the installation script keeps the absolute paths when creating backups.

sudo tar -Jxvf /etc/nixosbackups/backup.tar.xz ``` Backup of the custom software configurations :

```sh

Warp into the system root folder

cd /

Clear the system configurations folder before installing the backup

sudo rm -rf /etc/nixos/

Extracting the softawre configurations backup, since the installation script keeps the absolute paths when creating backups

sudo tar -Jxvf /etc/.dotfilesbackups/backup.tar.xz ```

The backup names use the pattern : backup_YYYYMMDD_HHMMSS.tar.xz so a backup named backup_20241231_002816.tar.xz would have been created the 31th of December 2024 at 00:28:16 in the 24 hours format.

Switching the system on the backup : sh sudo nixos-rebuild switch --upgrade-all

Once this command is finished, reboot using the sudo reboot now command or the system's UI.

Removing previous configuration backups :

If you want to delete the backups whose been generated, in order to earn some more storage space, you only need to clear the following folders :

  • System configurations backups : /etc/nixos_backups/ using sudo rm -rf /etc/nixos_backups/
  • Custom configurations backups : ~/.dotfiles_backups/ using sudo rm -rf ~/.dotfiles_backups/

Sources

Official sources : - :snowflake: NixOS packages registry : https://search.nixos.org/packages - :snowflake: NixOS options registry : https://search.nixos.org/options - :snowflake: NixOS Wiki : https://nixos.wiki/

Community managed sources : - :house: HomeManager options registry : https://home-manager-options.extranix.com/?query=&release=release-24.11 - :snowflake: NixOS community hardware config collection : https://github.com/NixOS/nixos-hardware

Contributions

Alt

Contributing

In order to contribute to this project, you can fork the project and create pull request against the main repository.

Keep in mind that this configuration is dedicated to computer science learning, and doesn't want any user-specific configuration.

License

This project is licensed under the MIT License

Owner

  • Name: Altaks
  • Login: Altaks
  • Kind: user
  • Location: France

I'm currently 18yo, french student.

Citation (CITATION.cff)

cff-version: 1.2.0
message: "If you use this configuration, please cite it as below."
authors:
  - name: Altaks
    orcid: https://orcid.org/0009-0001-6791-4435
title: "NixOS Polarflake"
version: 1.0.0
date-released: 2024-12-31
url: https://github.com/tauri-apps/https://github.com/Altaks/NixOS-polarflake

GitHub Events

Total
  • Issues event: 10
  • Watch event: 3
  • Delete event: 8
  • Issue comment event: 1
  • Public event: 1
  • Push event: 43
  • Pull request event: 4
  • Create event: 8
Last Year
  • Issues event: 10
  • Watch event: 3
  • Delete event: 8
  • Issue comment event: 1
  • Public event: 1
  • Push event: 43
  • Pull request event: 4
  • Create event: 8

Committers

Last synced: 10 months ago

All Time
  • Total Commits: 49
  • Total Committers: 1
  • Avg Commits per committer: 49.0
  • Development Distribution Score (DDS): 0.0
Past Year
  • Commits: 49
  • Committers: 1
  • Avg Commits per committer: 49.0
  • Development Distribution Score (DDS): 0.0
Top Committers
Name Email Commits
Altaks a****v@g****m 49

Issues and Pull Requests

Last synced: 4 months ago

All Time
  • Total issues: 8
  • Total pull requests: 5
  • Average time to close issues: about 2 hours
  • Average time to close pull requests: 1 minute
  • Total issue authors: 1
  • Total pull request authors: 1
  • Average comments per issue: 0.0
  • Average comments per pull request: 0.0
  • Merged pull requests: 5
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 8
  • Pull requests: 5
  • Average time to close issues: about 2 hours
  • Average time to close pull requests: 1 minute
  • Issue authors: 1
  • Pull request authors: 1
  • Average comments per issue: 0.0
  • Average comments per pull request: 0.0
  • Merged pull requests: 5
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • Altaks (8)
Pull Request Authors
  • Altaks (5)
Top Labels
Issue Labels
enhancement (4) good first issue (2) help wanted (2) bug (1) documentation (1)
Pull Request Labels
enhancement (4) bug (1)