Meetups/Infra/2024-03-25

From Noisebridge
Jump to navigation Jump to search

We opened chatting about companies in the news, big events in gutting-acqui-hire, game dev platform redefinitions. We discussed nix, a lot, maybe too much, but maybe not enough. We came up with a list of koans, little tasks and self-tests, to help particpants learn about infrastructure.

Introductions[edit | edit source]

  • Loren - host meetup, I like having these discussions, hosting these discussions, teaching and learning catches the eye.
  • Robert - software engineer. Want to host a nix meetup. Love taking about infrastructure.
  • Henry - software engineer, same as last week, no agenda
  • Doug - here to learn, not a software engineer.
  • Gwenn - here to learn, I like free software
  • Matt - used to do sys admin stuff with Loren at Berkeely, here for the vibes
  • [name] - [background]. [goals for meetup, or interests to explore]

Lesson or Demo[edit | edit source]

(TODO add description here.

  • Describe meetup structure
  • pad . riseup . net / p / nb - meetup - infra

)

  • Godot - logo newly on wall, pronunciation
  • Unity CEO - Jon Riccitiello
  • Microsoft - gutted, hired team out, of company. $600M, for 20 people.


  • Topics:
    • Tasks - command-line things.
    • Nix

Robert, want to run Nix meetup. Start a company, consultancy? It was a delight to find and use Linux, and nix feel like the endgame.

Easier to build a docker container with nix, than with docker. Zee (sp TODO) talk at NixCon, last week. Docker has better layer-building strategy. Optimal layering of

  • Adopting of nix, into dev environment. Byte-for-byte reproducible.
    • Jordan: set up for nix


  • Jordan uses nix flakes, for developer environment
  • Used to bundle editor into development environment. But this doesn't share nicely with others. A minimal development environment, with nix.
  • Ways of not using layesr - just nix building, raw
    • Cache per layer
    • Mount /nix with nfs - since it's idempotent for built packages. (Conflicts with package database though, sqlite, and some other pieces.)
  • Once you have nix working, it does obviate the need for docker.
  • Nixery, Docker image registry: https://github.com/tazjin/nixery
  • Nix separates concepts of build inputs and native inputs. Allow you to cross-compile for different architectures.
  • nixpkgs -
  • Building a VM image, for QEMU, to run a whole system in the virtual machine.
  • Jordan - flake used when doing linux kernel development.
    • A hermetic makefile.
  • Robert - you invest all this time to make the build work, and you get the confidence it's going to work again tomorrow

Do you need help typing notes? - Cloud

One thing I've done - Nix store? Hesistant to leap - delete it, you don't know if you could get what you need back. Dig into a new dev channel to figure out what revision I have, break everything in my system, turn on super heavy GC nix store - take time to rebuild the world so long as I have a source available.

  • Impermenance mode, run it on my servers.

Autonomous servers? No file except flake.nix file from 2 years ago. But into file nyx develop - version from 2 years ago - build from cache 2 years ago - think about - peak around - maybe get around to updating it.

Sometimes you have to install them in the right order - drivers are a unique nightmare, esp graphic drivers - you could build imperfectly it doesn't mean you could run it.

So if you are writing a graphing compositor? On wayland. Compositor with older drivers, you can't build it for a new one, the drivers don't match you don't have the right drivers intalled - but bring file to computer with the correct driver - build exact same program - build it on a computer and send it to binary cashe - run it - you can't run it but you could still build it.

Gigapackage? Build deterministic do I want to build the next package.

You could even just nix.p. Create a virtual...

People build infrastructure around it - nix package - 10,000 - build to a point where you say I want to build hello-world without having to specifiy a compiler - its all there. (...to foreshadow the clarification that follows: It's in the nix system version, which is like a release.)

Reproducibility > you don't have to specifiy the compiler - compiler version - some Code in C version 1.0 then build 1.1 which compiler - you have to do the same thing.

what specify a nix package - recode - fetch prompts - compiler revision with the hash to make sure it is always the same. Override that - and up the compiler - new revision with fixed outlet -

Deterministic - which compiler to use?

Deterministic - at hello world version? Could be used - explicitly implied

It's implicitly specificied in the langauge function - any implication of that funciton.

If there is one bit oof color - stream - 22.21.5?

Next one is 24.01 Base system - then specify versions - while scratching your heads. Ellicit sugggestions from everyone - of task that people here could attempt 5-30 mins task - could be a little self-test -- learn the next language using cones as programming exercises before?

Peter Norvig. Is that a real name? Github koans, a whole tag category for repos.

Similar - certian milestones - quick ways of testing syntax - what does that look like?

Repo - cone? Plus language - github topic on it. Command line challenges little test you could give to someone else - developer at job - introduce to NB infrastructure.

Started with one: Unix tools command line to create a program that solves wordle (horrible game) dictionary speak items into the notes. Starting NYX task. Or a way to investigate these - trail of a few. I always lose them!!! >:(

For wanting people to start next: package in a few mins. That is gentle way to start using as package manager - install on any system - you don't have to install full-nix os.

I really hate myself for saying this: Did a few questions in Nix on Leet code language.

Personally used. Haskell than Ruby.

(it's ok to be editoral / summary) I refuse.

Programming - google dev - haskell version - every nix function -- Been around for a while.

Another client - personally useful to me - finicky internet default debugging turn it on and off again - automate that again - pretty nice - turn something off and on. DMS. Server.

  • koans - norvig

Interface to setup.

  • "Activity Watch" - monitors what you're doing. - what you are doing its a server - its easy to just setup - understand how to run a server and stuff.

Start using docker filled - still want to keep the plug DPS - how would I specify NixOS. Raw docker file to nix?

What language are you using? Python!

Python on nix is not the best. (omg trash talking python)

"Poetry" python build system enviroment. Literally spent poetry file - convert poetry- to-nix - 200 lines - not touched it since 6 months ago.

Python infrquently packages - that feels a little dirty everytime you run it :D

Poetry will let you do python package. Python - packaging is the most regional pieces of OS. Any distribution - one of the first thing getting packaged - Lots of people do Python - python code packaging before people figured out better ways using NIX. Python is one of the things that has 10,000 packages in nix itself. 2nix - convert project. what you will find is - there are 10,000 python packages all depending on each other - depending resitiution - most recent branch - not street python version - master range - thats why you stick with the poetry nix.

Gynasmium - multiplayer - machine learning not available on nix packages. Download the game - to rebuild itself - turns into a rabbit hole - poetry to nix - that is good and works well but not super famililar with poetry and tools - aws things installed - small python project handful of dependeancy may not have to do all that - first time building a docker image - I would not recommend going that route - poetry to nix - getting that to work ([difficult]) - but - its hard to just say anything when it works - it works!

When you play around with every system - any type of packaging in a single lagnuage - journal dependancy - C python under the hood you start overriding things - subdependancy you override to be able to - dependancny - nix package - package something simple - single range - simple no dependnancies -

Teams that have used NIX - NIX experts (1 - 2 people) you look at it steam stuff popped up, override, in order to be able to pinpoint that out - ff

Anyone else using nix? Pubically package something URL - Build process - type of stuff trying to this why python understand what they need to do. Vary specific - its complicated - but its not complicated - points behind - common theme - nix functions - nix post - time and works - you never have to think abotu it. this is the endgame.

Firefox dependancy route from 2003 It solves this elegantly - makes it easy . Software in 2024 - known application.

Press once more for a cone or task. Intro - lesson - something you think that ecompasses the base of the mountain of some useful task that you would recommend others. Dev shelf? Package manager - start using nyx as a package manager - any dev enviroment isoltation and dependancies - nix shelf. override this - highlight all the sloppy pracctices associated with python - exposes the messings that is software.

tries to layer a disipline - Amazing meme ----- astronaut image pointing at earth underneath a hood - useful factions?

  • "it's all bash under the hood"

One of the way it makes its build phase - no access to internet during the build. Docker image - every line - abritrary commands - fetch source from github and stuff - part of the build phase other thing it does - when the program is getting built - all the actual dependancy - patches out put nix.

Never thought in the state of python - not necessary wrong - but people sprint to goals - I would have thought it was a pipedream - software ecosystem - reproduce it. 8000 projects the nix packages. gitrepo - its a HUGE repo. half a gig. that is up from 27 - 2 and 3 years doubled in size - 10x.

Just people who keep saying "ITS A NEW VERSION OF THIS" its usually a patch version.

There are still a lot of dates on it - decentralized more - If a project has flake.nix. Nix.run.git.repo. don't have to clone the repo - downloading one single command. You can run it without "installing" it.

Like you can do `cargo run`

(slow down -- it's ok. better to miss things. add new key words )


Which version of programming - miniverison installed - not everything is built on master - one program - CI system - added that nix package inputs - give me - install package from this revision but don't touch anything - the program ran it and didn't pollute the enviroment - nothing broke.

Nix form is pretty active. There is even - link it!!! :D

https://nixos.org/manual/nixpkgs/stable/#chap-language-support <- diff programming language support

man pages

Framework strategies for building - good tips Sometimes even found that sprinting to get a dev self built - 99 percent for 1 percent of the work. There is so much to it - that using github search - its heavily documented. Githhub -flake.nix? Function APR packae - basically building packages is using useful batchfunction. build sequence in batch. documentation in it in places - search the github repo. library function for the batch.

We want to get us to start doing things >:(

   Nix koans. 

Pick a koans! And go do it! >:((((

   Or an edited version. Go! Get down the rabbit hole to these task! Amazon - these things implies spending some money or server task - getting web server setup with certificates. It's all on the journey, if its easy its easy.

Own domains - Buying a domain and don't pay a bunch and make sure the reaccuring payment is low. Avoid front-end figure out how to build yourself. Use github pages - many websites - 5 words github website on everything. Most of these codes have a github - books - repo to specific branch - have a domain - if you don't have any websites - complicated when you start paying for it. It's very free and very easy to set up a javascript base website. If you ever want to do a webapp that runs locally. Javascript - to do list tracker writes program that saves the local storage - developing software - domain and its free - thats how you host useful.

Cloudflare pages - backend - frontend - It has some server side rendering now. If the charge - run nix.js.something pick your database fully html - add caveat - cloudflare pages - nuxt.js, next.js for vue.js.

They have a lot of good templating out of the box. UI. Documentation to it too! Backend function to 1 megabyte. Deply it on netlify :)? (Wwhat is this??) no default cap on the filling. Someone DDOS their site, 10,000 hacker new years. CEO posted on hackernews support. Anxious about using it - messed up - sprinting to a goal at that point. you don't need to run that risk - cloudflare - it was over a megabyte. Limit on how large. For the serverless functions - honestly - serverless functions - its built it to rust. at first it was fine but then there is a construct that it has with its content file - markout file - increase my bundle size signifcantly. javascript sucks at small builds.

Compressor for CSS. Without changing ASD part? Writing it in Javascript - I've been in webassembly and rust. Overkill but a fun project. Implemenetning it at all is a verrrry satifying finish.

Game of life in haskell - try it.

The answer is don't use list. Everytime uses haskell - get lost in the sauce.

standard library is not very good - install a dozen packages - the standard library is rather bad - its terrible - string stuff - lets start trash talking stuff! :D

Mana transformer stuff? Am I hearing this correctly? Haskell - once I have learned all the theory stuff - nope the pracctice is. Procredural language - some problems too mathematicals - procedural -

Language for livecoding music, "Tidal", built on haskell. Gave up using it. Cannot figure out how to get it build.

Two competing packaging - python not userfriendly - haskell stack - trade off - using a language and making a language bearable enough so people use it. Stack is a specific repositoary competing respository (that is how you know its bad)

Haskell is necessary to develop - list - Lots of stuff is hard on software - haskell -

Lots of videos on Haskell talks - largest - google always recruiting 30-50 self professed users of it.

theory function - not so much about the functions - its about defining code in a way that is independent of how its .. its very mathmatics heavy - very commonly reaccuring concepts in computer programming - might at first think that its complex but then realize contianers and streams commonly occuring - instances of helps you understand abstractions much better, trying to compute some connection

Some connection between functional programming, and compute-in-memory. Take over pls :) Bathroom >:( omg recurrsuion!

Rust. First compiler, written in OCaml, able to bridge the gap, of functional, but able to use a memory model. (Laziness is very difficult.)

Lauren - With immutability you have a stronger binding between, memory address and its contents.

With Haskell the same thing that makes it difficult to use --

Great libraries - worse fundamental problem - practical - better tooling - better abstract dates? Very hard to debug and troubleshoot your code - transformer stacks - add velocity into your code all the way back to your once ubermya? Login states - logs everywhere - one giant one application - debug - it complier says - researching pilot. Bad debugging. Complier make it more robust - loggin - recording certain stuff - you cannot easily you. connect state side effect - function signature - stateful monad??

Entire function in codebase - Haskell - chatwrites Haskell

Ending: What should we explore next week? :D he was 7 years old. dream about java. simple things - koobra. hear about nix. slowly.

When I was young, I used to plan what I would dream about. Now that I'm older, I lie in bed and dream about java, how to get these 2 programs to work.

Surprising moment; thing you want to carry next week. Impermance mode - running - xxxx got it below

  • hugs Loren, runs away, thank you for helping me procrastinate on my work* -Love Cloud

Wait what is group theory?



  • koans - norvig
  • Tasks -- challenges, self-tests, koans, getting started milestones
    • wordle - word finding, with unix cli tools.


    • nix - get it installed as a package manager. Can install it without installing a full system.
    • nix leetcode some examples https://github.com/r33drichards/nix-leetcode
    • nix - make a development flake, a dev shell, after a package manager.
    • nix + git for static website - write a git-comiit hook to build the site on every commit (~ pushing maybe a separate step).
    • on a server, get a web server set up, with certificates
    • Go to cloudflare pages, and set up a front-end only website, that does something

https://worker-noisy-surf-88a6.doug-edmond.workers.dev/

      • Game that runs in javascript. ToDo list tracker that uses local storage.
      • Netlify, vercel. Github Pages (won't build for you)
    • Game of Life, is a good koan. Robert - did in Rust -> WASM. Implement it at all.


    • network issues, script for yourself, your system(s) - turning it off an on again, or diagnosis. ip, icmp, dns, tcp, udp, speed.
    • package something python to nix - set up with poetry, build (as docker container?), deploy somewhere?




  • outros (favorite / most surprising comment/lesson today -- what should we explore more next week)
    • next week
    • pair-program a haskell program, as a group.
    • Robert: surpirse: someone else running in inpermanence mode in nix, do: definitely some of these koans
    • Henry: surprise: something about WASM, something I'll have to do more looking into. do: some haskell next week.
    • Loren: do: build an infra-meetup server -- irc, information environment.
    • Doug: do: the shared haskell program
   nixOs modules also
    • Gwenn: surprise: messy, so much. do: [pass]
    • Matt: surprise: I'm now slightly considering yolo-installing nixOs on my laptop. (will ) do: down for the haskell
    • Jordan: surprise: haskell pure coloring, logging effect. (You have to explicitly write. Monads are code, much more difficult to compose, add logging, add logging to everything -- reimplement from scratch or find something), do: build a hello-world server, and how to deploy it, fun to see everyone's variants.

https://www.jdoodle.com/execute-haskell-online

  • Shell, web services, self-hosting, networking!

Questions, Discussion, or Coworking[edit | edit source]

Forms for meetup presentation proposals. https://forms.gle/oUGKBURo1rXUb8ch8

  • [Issue]

For next time[edit | edit source]

Questions[edit | edit source]

Readings & Exercises[edit | edit source]

  • Readings
  • Exercises

Join online[edit | edit source]

  • Try it yourself!
    • Join libera.chat #nb-meetup-infra

https://www.noisebridge.net/wiki/Meetups/Infra