# Nixified BBB Demo
reproducible development and maintainment

---
### Goals
- Universal development environment
- Usage of Nix development environment
- Reproducible Containerbuilds
- Usage of Nix DockerImage
- Pkging for NixOS
---
### First of all
- What is Nix?

---
- How does it work?

---

---

---
### Enter the development environment
```bash
nix develop
```
---
### Reproducible Containerbuilds
Issue with Docker

---
Most package managers will write files to shared global directories like /usr, /bin, and /etc.
As a user you might manually create rules to improve the behavior of the cache: add your code towards the end of a Dockerfile, or install common libraries in a single RUN instruction, even if thy don’t want them all.
---
Building Docker Image with Nix
```bash
{
inputs = {
docker-nixpkgs = {
url = "github:nix-community/docker-nixpkgs";
flake = false;
};
flake-utils.url = "github:numtide/flake-utils";
nixpkgs.url = "github:NixOS/nixpkgs";
};
outputs = { self, docker-nixpkgs, flake-utils, nixpkgs }:
let
system = "x86_64-linux";
pkgs = import nixpkgs { inherit system; };
buildImageWithNix = import ("${docker-nixpkgs}" + "/images/nix/default.nix");
in rec {
# TODO ADD nginx
packages.nixImage = buildImageWithNix {
# All of this is required by the function
inherit (pkgs)
dockerTools
bashInteractive
coreutils
nix
xz;
# TODO add BBB config
extraContents = with pkgs; [
];
};
packages.default = pkgs.dockerTools.buildImage {
fromImage = packages.nixImage;
# ...
};
};
}
```
---
### Nixpkging for BBB in
- [Current Development](https://github.com/yVieta/bbb4nix)
- Moduls have to be build
---
#### Install nix ontop if your System
https://nixos.org/download#nix-install-linux
---
#### Usefull tools
- [FlakeHub CLI](https://github.com/DeterminateSystems/fh): Creating development environmens
- [Nixpacks](https://github.com/railwayapp/nixpacks): Applications transform to docker Images
- [Arion](https://github.com/hercules-ci/arion): Docker Compose with nix
- https://docs.hercules-ci.com/arion/
---
#### Work in progress
- Container build with nix: https://github.com/yVieta/bbb-container
- Flake build : https://github.com/yVieta/bigbluebutton
- Rewrite for porting to official Nixpkgs: https://github.com/yVieta/bbb4nix
{"description":"type: slide","title":"Nixfied BBB","slideOptions":"{\"controls\":true,\"progress\":true,\"defaultTiming\":120,\"slideNumber\":false,\"history\":false,\"keyboard\":true,\"overview\":true,\"center\":true,\"touch\":true,\"loop\":false,\"rtl\":false,\"shuffle\":false,\"fragments\":true,\"embedded\":false,\"help\":true,\"showNotes\":false,\"autoPlayMedia\":null,\"autoSlide\":0,\"autoSlideStoppable\":true,\"autoSlideMethod\":\"Reveal.navigateNext\",\"mouseWheel\":false,\"hideAddressBar\":true,\"previewLinks\":false,\"transition\":\"slide\",\"transitionSpeed\":\"default\",\"backgroundTransition\":\"fade\",\"viewDistance\":3,\"parallaxBackgroundImage\":\"\",\"parallaxBackgroundSize\":\"\",\"parallaxBackgroundHorizontal\":null,\"parallaxBackgroundVertical\":null,\"display\":\"block\",\"spotlight\":{\"enabled\":true},\"allottedMinutes\":5}","contributors":"[{\"id\":\"f4b59643-b665-4e32-b458-c01323595782\",\"add\":5978,\"del\":3035}]"}