Slide 1

Slide 1 text

Flox as a Guided Path for Nix Michael Stahnke VP Engineering at Flox (flox.dev) @stahnma

Slide 2

Slide 2 text

2 Not a sales pitch @stahnma

Slide 3

Slide 3 text

3 Thoughts and approach @stahnma

Slide 4

Slide 4 text

Edu Career 4 9 Years 8 Years 4 Years About a Year

Slide 5

Slide 5 text

5

Slide 6

Slide 6 text

6 Packaging and Software • Founded EPEL repository • Maintained more than 200 packages for Fedora • Ported Ruby to AIX • Packaged for AIX, Debian, Red Hat, Solaris, Mac, Windows, Arista Switches, Cisco Nexus Gear, etc @stahnma

Slide 7

Slide 7 text

7 For 15 years, I’ve been doing developer and infrastructure tooling @stahnma

Slide 8

Slide 8 text

8 @stahnma

Slide 9

Slide 9 text

9

Slide 10

Slide 10 text

10 Result: Didn’t touch it again for years. @stahnma

Slide 11

Slide 11 text

11 Packaging All the Things @stahnma

Slide 12

Slide 12 text

12 Wrote our own tooling @stahnma

Slide 13

Slide 13 text

13 Built our own CI system from the ground up @stahnma

Slide 14

Slide 14 text

14 Nix solved portions of that @stahnma

Slide 15

Slide 15 text

15 I <3 Packaging I <3 Developer productivity Let’s do this. @stahnma

Slide 16

Slide 16 text

16 A New Nix User

Slide 17

Slide 17 text

17 Why is this so complicated? @stahnma

Slide 18

Slide 18 text

18 Expression Profile Derivation Purity Shell Flakes Closure (not Clojure) Storepath Purity @stahnma

Slide 19

Slide 19 text

19 There are debates about what “install” means… @stahnma

Slide 20

Slide 20 text

20 Other problems Can’t find headers Can’t find libraries Shell vs develop Experimental Features Is this a package manager, a package repository, an OS, or a tool? @stahnma

Slide 21

Slide 21 text

21 Commands with spaces all need extra arguments saying it’s ok to use commands with spaces @stahnma

Slide 22

Slide 22 text

22 You start with a build…then you write code? @stahnma

Slide 23

Slide 23 text

23 Nix starts in the deep end @stahnma

Slide 24

Slide 24 text

24 So, let’s take a step back @stahnma

Slide 25

Slide 25 text

25 What’s nix awesome at? @stahnma

Slide 26

Slide 26 text

26 Nix Benefits • Reproducibility • Cross Platform • Trying out software • Caching builds and tests • Huge Package Repository @stahnma

Slide 27

Slide 27 text

27

Slide 28

Slide 28 text

28

Slide 29

Slide 29 text

29 Tangent

Slide 30

Slide 30 text

Customer Viewpoints 30

Slide 31

Slide 31 text

31 @stahnma

Slide 32

Slide 32 text

32 @stahnma

Slide 33

Slide 33 text

33 @stahnma

Slide 34

Slide 34 text

Everyone knows that debugging is twice as hard as writing a program in the first place. So if you're as clever as you can be when you write it, how will you ever debug it? — Brian Kernighan 34

Slide 35

Slide 35 text

35 Back to our regular program

Slide 36

Slide 36 text

36 Desire for simplicity. @stahnma

Slide 37

Slide 37 text

37 Desire for nix benefits. @stahnma

Slide 38

Slide 38 text

38 Desire for Cross Platform Work @stahnma

Slide 39

Slide 39 text

Workflows 39 • Have a way to contribute to a project (locally usually) • Set environment variables in some way • Configure the environment • Run Tests • Have development look like something that will run in prod • Use my editor • Use my preferences @stahnma

Slide 40

Slide 40 text

40

Slide 41

Slide 41 text

41 Why? @stahnma

Slide 42

Slide 42 text

42 Can we build upon the last 20 years of Cloud? @stahnma

Slide 43

Slide 43 text

43 Can we build upon the last 20 years of Nix? @stahnma

Slide 44

Slide 44 text

44 Can we do this without abandoning existing knowledge sets? @stahnma

Slide 45

Slide 45 text

45

Slide 46

Slide 46 text

Thrown away concepts using cloud native architecture 46 Multiuser systems Multi-application systems Debugging using a shell Process and User accounting @stahnma

Slide 47

Slide 47 text

Added complexity when using Cloud Native 47 Debugging tools Observability tooling IAM Paying for services to monitor services to run services to monitor services YAML…fun? Sure. Fun. @stahnma

Slide 48

Slide 48 text

Peel back the complexity Onion 48 There is a lot to like about Cloud Native Architectures. @stahnma

Slide 49

Slide 49 text

Peel back the complexity Onion 49 There is a lot to like about traditional Unix/Linux concepts. @stahnma

Slide 50

Slide 50 text

Peel back the complexity Onion 50 Why are these mutually exclusive? @stahnma

Slide 51

Slide 51 text

Peel back the complexity Onion 51 Build on the power of nix. @stahnma

Slide 52

Slide 52 text

Peel back the complexity Onion 52 Build on the simplicity of an environment you can work with in your shell. @stahnma

Slide 53

Slide 53 text

What workflows matter to a user? 53

Slide 54

Slide 54 text

54 Search, install packages @stahnma

Slide 55

Slide 55 text

55 Specific versions of packages @stahnma

Slide 56

Slide 56 text

56 No variance @stahnma

Slide 57

Slide 57 text

57 Develop, then build, then operate @stahnma

Slide 58

Slide 58 text

58 Partial SDLC adoption @stahnma

Slide 59

Slide 59 text

Peel back the complexity Onion 59 Starting with the build is unfamiliar @stahnma

Slide 60

Slide 60 text

Peel back the complexity Onion 60 Share your environments with colleagues, production, friends, strangers @stahnma

Slide 61

Slide 61 text

61 Hypothetical Learning Curve @stahnma

Slide 62

Slide 62 text

Peel back the complexity Onion 62 If you know nix, great. Perhaps this can help with others on your team or department. @stahnma

Slide 63

Slide 63 text

Peel back the complexity Onion 63 If you’re new to nix, I hope this an easier approach. @stahnma

Slide 64

Slide 64 text

Peel back the complexity Onion 64 Modern SDLC wants what nix brings. @stahnma

Slide 65

Slide 65 text

65 Nix Benefits • Reproducibility • Cross Platform • Trying out software • Caching builds and tests • Huge Package Repository @stahnma

Slide 66

Slide 66 text

66 Approach • Centered around “Environments” • They can be used at any time in the SDLC • They are portable • They are sharable • They are built upon nix and share some of the best nix benefits. • They are not 1:1 Nix • Packaged software versions over time • Auditable @stahnma

Slide 67

Slide 67 text

67 Approach • Meet technologists where they are • Compatibility with existing SDLC approaches, tools, processes • The developer experience is paramount @stahnma

Slide 68

Slide 68 text

flox.dev