About this video
What You'll Learn
- Install Comtrya from cargo, shell script, GitHub releases, or package managers.
- Write YAML or TOML manifests with actions, dependencies, and selective applies.
- Use where clauses and action variants to handle platform-specific behavior.
Todd Martin, primary maintainer of Comtrya, joins David to walk through this Rust-based workstation configuration tool. They cover installation, writing YAML/TOML manifests, dependencies, conditional logic, action variants, and user, file, and git actions.
Jump to a chapter
- 3:25 Introduction and Guest Introduction (Todd Martin)
- 5:08 What is Comtrya?
- 6:08 Comtrya's Purpose and Origin Story
- 8:27 Todd's Role as Maintainer and Project Momentum
- 10:36 Supported Platforms
- 13:18 Challenges of Cross-Platform Support
- 15:06 Overview of Comtrya Documentation
- 20:51 Installation Methods
- 22:27 Writing Your First Manifest
- 23:36 First Steps: Running a Command
- 29:57 Installing Packages (`package.install`)
- 32:45 Structuring Manifests & Dependencies
- 35:01 Demonstrating Manifest Dependencies
- 39:00 Output and the Plan Stage
- 41:14 Exploring Conditional Logic (`where`) and Context
- 48:41 The Main Comtrya Configuration File
- 51:11 Action Variants for Platform Differences
- 57:16 User and Group Management Actions
- 1:05:04 User Management Nuances and Feature Ideas
- 1:06:38 Review of Actions and Future Scope
- 1:07:01 File and Directory Actions
- 1:09:55 File Actions, Syscalls, and Privilege Escalation
- 1:12:48 Git Integration History and Features
- 1:19:03 Git Action Parameter Change
- 1:20:40 Looking Ahead: The Future of Comtrya
- 1:21:11 Release Cadence and Upcoming Features
- 1:24:05 Feature Ideas and Design Philosophy
- 1:27:08 Conclusion and Call to Action
Full transcript
Generated from the English captions. Timestamps jump the player to that moment.
Read the full transcript
3:25 Introduction and Guest Introduction (Todd Martin)
3:25 Comtrya. Welcome back to the Rawkode Academy. I will explain that Comtrya reference very, very soon. But I wanna welcome you back. Happy New Year, and this is the first stream of 2025 and a very special one for me because we're taking a look at a project I've been involved with for a long time now, and I get to be joined by someone I call a friend. Hey, Todd, man. How's it going? Not too bad. Yourself? Yeah. All the better now. You know, at the end of the day, I get to end in a fun way, which is, you
3:56 know, with some pretty cool dev tools written in Rust. We might as well throw that out there pretty early. But before we talk more about Comtrya and what we're gonna show today, do you wanna just give a a little bit of an introduction to the audience at home? Alright. Once again, Todd Martin. I'm one of the maintainers, I guess, now probably the primary maintainer since I've kinda got the free time to look after it. Software engineer during my day job. I slinged C Sharp for a smaller company and then do Comtrya during my free time. I first
4:30 came to it because of another friend, Michael Ream, out of Germany who actually pointed me to Comtrya for a project we were looking at for VSD and then ended up becoming a contributor and then later on a maintainer. Alright. Even if there's a very annoying buzzing sound, I've turned off a space heater because it's pretty cold here. And if that doesn't fix it, I will pop a cable and put it back in, which is the universal answer to all audio issues. Mhmm. So let me know in thirty seconds if that goes away. Alright. Thank you for the quick introduction.
5:08 What is Comtrya?
5:08 Why don't you tell us what Comtrya is, what it does, and what you were potentially looking to use it for? So, originally, I believe you started it as a dot file manager tool and kind of the primary purpose, and it's kind of grown in scope since then to kind of include a lot more system management general system management and configuration outside of just specifically managing dot files. The future of it for me, as I see it going, is leaning more into the the system configuration and management portion, and that's actually what I use it for.
5:45 I've been using it a lot at work, the stand up systems, and have a configuration and ease deployment. Thanks. Yeah. I mean, that's I don't know the blessing or the curse of all projects. Eventually, scope creep happens, and it does more and more. So, yeah, we could talk about how the project is growing. But maybe you could take what you said and condense it into, like, a thirty second pitch for someone who's never used Comtrya before. Why should they install it, and what is that kind of default use case? What would they use it for? Oh,
6:08 Comtrya's Purpose and Origin Story
6:21 that's a good one. I never really thought about, like, a thirty second pitch. I mean, I put you on the spot while I was, you know, fixing that cable, but apparently, I'm back. Yeah. I would say, if I had to quickly get one off the top of my head without thinking too deeply into it, say, dot file system configuration management tool written in Rust with hopefully bringing some of the safety that Rust brings, with pooling, really. Yeah. I'm I'm gonna pay it on to that just because, obviously, I am very familiar with Comtrya. To anyone who doesn't know, I
7:06 bootstrapped the project four, five years ago now. I think it was '20 late twenty nineteen. Maybe it was 2020. I should twice. I don't even know. But my I was trying to scratch my own itch. I am a serial OS wiper. Like, I like to format my machines pretty much religiously every 30. Religiously might not be the right word. But with thirty day cadence because promotes better habits with my machine. I don't like clutter. I like a fresh system. I don't wanna lose anything really this older than thirty days. It makes sure that I back
7:41 stuff up where I need to back it up. And, also, it's just fun to distro hop. You know, I'm a Linux user. So, you know, whether I'm running XSOS today, I might be Arch tomorrow. Next week, I might be in Silverblue again. Like, I'm just insatiable when it comes to Linux, and I'm always jumping about and experimenting and kicking tires on things. And Comtrya is the reason I started a project was to, okay, how do I get from, oh, shit, here's the fresh machine to how do I get back to work without wasting an entire day?
8:08 Because let's be honest, right, you get a new machine so at least two days of just messing about installing stuff and testing out new extensions. I I don't know. Maybe I'm just terrible procrastinator. I I can't stop installing software, and Comtrya was trying to alleviate the burden of some of that at least anyway. Mhmm. Okay. So how long have you been you know, you are the the primary and I think almost sole maintainer. There's a few external contributors that are obviously submitting patches and and using the project, but, know, you've been working on this. I'm I I I don't
8:27 Todd's Role as Maintainer and Project Momentum
8:39 even know. Like, a year now? Has it been that long? Has it been less? I'm not sure. Yeah. I think it was about this time last year where you had brought up that you were getting busy with you going out and starting your own thing and meeting one of us to kinda meet or Stephan, who's also in chat, kinda picking up some of the some more of the deeper maintainership duties. Actually, I think it was a little bit before that that you added me to the crates so that way I can start doing releases. Yeah.
9:10 Last year where I think you had mentioned that you were getting a little busy, and you need one of us to kinda take it up more. And then it came up over the summer, and I kinda took it the rest of the way. Yeah. And I think you've shipped quite a lot in that time. You know? And don't worry to the people watching going, just get just show me a terminal already. Right? We're gonna get hands on very, very soon. But, you know, for me personally, having not having not oh, that's a terrible thing. Not having the time
9:38 to work on a project like Comtrya was really disappointing to me because it solves an itch. It's a space that I like. But just seeing you deliver new features month after month over the last year It's really kinda like it's it's I could smell on the face. I'd be so happy to see the project moving on and changing. You know, the TOML support, I think, was fantastic, and there's a whole bunch of other features, like, you know, supporting run zero as a privilege elevator. It's just so cool to see all these things coming together. I've seen more activity on
10:10 the GitHub across issues and pull requests. You know, that little bit of momentum that you pushed into the project is now paying compound dividends as far as I'm concerned. I'm seeing more adoption, more interest, and more engagement. So I I I could not be happier with the position of Comtrya today, and I'm excited for us to share that screen, get a terminal open, and actually show people how they can get started and hopefully make their lives a little bit easier. Yeah. But before, you know, you were an early adopter of Comtrya too. I mean, we're going back years
10:36 Supported Platforms
10:41 now. Right? Yeah. And one of the things that I think drew use of the project and is still very prominent today is that we always say Comtrya should be able to run anywhere. So maybe you can give a little bit of flavor and color on why that's a goal and the kind of platforms that we support. Yeah. So guess start off with the platforms we support. Windows, Mac OS, Linux. There's a little bit of an asterisk to that. The only reason I would say that there's an asterisk to that is because of providers, and it's like, there's hundreds of distros.
11:12 If you look for well, as viewers will see later, there's, like, a package installed so that way Comtrya can install packages. We don't have every distro in there, but if we can add it, I'm more than happy to. I just need to know what the distro is so that way I can add it. But it's also impossible to add every possible distro in existence there. But for the most part, we can support any Linux. And then BSD, but not all BSDs right now. The main ones are free BSD and net BSD. I think in theory, most everything should work
11:48 except for maybe the package install on Dragonfly BSD, and that's just because free BSD and Dragonfly BSD, while they are two distinct projects, still share a lot of a lot of similarity. OpenBSD has kinda been the painful redheaded stepchild, unfortunately. Like, it's a platform I would love to support, but there are some hurdles that have to be overcome and not just by me to fully confidently support OpenBSD. We technically could today. The reason I don't is because and why I don't do anything specifically is because the Rust tool chain tends to fall behind often in OpenBSD.
12:26 Last time I looked, there's one poor soul who's maintaining that for OpenBSD, and, it's kinda like a constant game of catch up for them. Yeah. I mean, I think there's still pretty wide support right off the bat. And and the Linux thing is obviously tricky because you don't wanna have to write Rust code to support a new package manager. And then maybe this is something we could talk about at the end, but, you know, just thinking about that for all four seconds there. Like, there's no reason Comtrya.YAML is a config fail. It couldn't support specifying
12:59 custom installers because all you need is a command with some arguments for each of the different verbs. So maybe we're maybe it just gonna turn into let's let's fail a pull request and that's some cool functionality. But Yeah. Yeah. We could we could we could make that easier for people that wanna experiment with different test tools that don't have hard coded support. Definitely. And I guess one thing to add with platform support, that's probably one of the more difficult aspects of the project. I do get people who hit me up on Discord and issues where they're like, hey. I wanna do
13:18 Challenges of Cross-Platform Support
13:29 this really cool thing. And then the battle is always, how can I implement a feature that doesn't either break something on another operating system or cause massive issues? Really, the biggest one here being Windows because, you know, a lot of things, especially since we do kinda shell out, work roughly the same between macOS, BSD, and Linux. Windows is kind of the different one here where it's not everything is one to one. For instance, like, a privilege escalation works totally different on the Unix c platforms. We can just sudo DoS run zero, but Windows apparently, we'll have sudo at some point. Last
14:08 I heard that they're implementing their own sudo and Windows preview at some point, so maybe that'll line up. But as far as I know, for most Windows systems, they don't have something that's equivalent. Hell, I mean, if they roll out schedule support, you're looking at a future where you could run a Comtrya apply and not only provision the Windows host, but multiple WSL virtual machines at the same time with one set of manifests. And, you know, the variant support and manifests as we're gonna get to soon, I I think is one of the superpowers of Comtrya
14:44 and one that I've definitely very poorly documented early doors, and it's getting better, but I don't even think we've tapped into what that enables enough. I think there's more to be done there. However, we have been talking now for the best part of fifteen minutes, and we haven't shown any code. And we've only said Rust once or twice. So Yeah. Maybe we should Before we jump in, do we wanna just kinda show up the documentation? Yeah. We should. Yeah. Definitely. K. Alright. Let me pull up the screen share. Alright. Your screen is up. We see the
15:06 Overview of Comtrya Documentation
15:25 Comtrya man. Oh, we haven't spoke about the name. So it's a it's a total Stargate SG one reference. Right? Like, I don't know if everybody has seen this episode, but it's one of my favorites. And I believe this man is called Hanlon. Yeah. Hanlon. And he says Comtrya, which is like their their greeting and their welcome. So yeah. Always makes me smile to see his face in the bee mooch. And it also gives the project a nice name, I think, little bit unique too. Don't think you said too. You Google it, and all you find is Stargate or
15:59 or a little Rust project. So Yeah. Kinda wanna show the documentation first just in case anybody wanna follow along. And as David had said, improvements to the documentation. This has been rather recent in the last year is moving it over to using MDBook, so adding more Rust tool chain in there. So there's another Rust reference for you. There's still some areas where it lacks, and I'm hoping to correct that over time. But as you can see, it's pretty easy to navigate. Got our introduction, a little rundown. I think most of this is from the older documentation
16:39 which you had on Gitbook. We got our supported systems, how we're gonna install it, or the different ways to install it, a little bit about CLI, the different commands that CLI has to offer, but the real meat of this documentation is here underneath the manifest and the actions. Nice. Yeah. I like this format much better than the the GetBook stuff. I mean, the GetBook was great, and, you know, they support open source by providing their platform for free. But I think the entire deployment pipeline you put together for this is is flick and quite quite nice to navigate. Yeah.
17:19 That's that's kinda why I like going with this option. So now the documentation is kept in repo alongside the code. I guess one complaint you could have is that every single time a pull request happens, even if the documentation doesn't change, technically, they get pipeline publishes a new version of the documentation. Okay. Maybe it's a little publishing when it doesn't need to. But the bottom line is it's, if somebody were to do a feature, they could have the code for the feature and the code for the documentation all in the same pull request. And once it gets pulled in, it's spam. It's
17:51 on the main branch of Comtrya, and the documentation is live immediately. Yeah. I think that one or repo approach. I mean, it's the secret sauce for these projects because the problem we had with my setup was people were sending really awesome pull requests, but the documentation was a different repository. It never got updated out of this month, if not longer behind. Mhmm. Yeah. This is cool. I like this. So Stefan is already in the chat, sticking me on it. So Stefan is correct. There there was an example written by me, unfortunately, that every time you ran the tests or
18:32 you ran against the examples directory, it would reboot your machine. And we thought this was a bug until we looked in the examples and realized that dumbass here had a special command run system control reboot at a Yeah. Underneath I've never done that again. Yeah. So so I guess some background. So it it was me coming into the Discord chat kinda like, guys, guys, I think we have a major problem. And I'm sitting here, and I'm like, okay. Because I didn't look at all the examples. I'm just running them and testing them for whatever I was doing at the time. And
19:08 then I started going like, okay. I'm gonna need to debug the kernel on this. So I'm sitting here doing all this, and then, yes, Stefan comes up, and he's like, it's probably because of one of our examples. We have a where clause where if you're on Linux, we just reboot the machine. Not not the my famous moment, but oh, well. Clearly, I've just been like, okay. What could a a good work clause be that's Linux specific? And I've just been, oh, yeah. System deep. And yeah. One idea. Yeah. For, for anyone, I guess a little bit of information about
19:41 that word clause and to give some information about it. Here in the Comtrya documentation, you see an example of it where we can have variants of a command. So we can kinda change the behavior of a certain action depending on, like, the operating system. And I think there's some other parameters, but probably the one that I've seen most commonly in other people's manifest is like, oh, if on Linux, do this. If on Oh, the repo is still there. In the example, but I believe I did actually it's just a copy and paste. Let's see. Go back.
20:16 Because I'm pretty sure I changed that out. I hope I did. Yeah. It was in here. I think I just changed it to a no? It's under variance, I think. Only variance. Only variance. Yeah. And I changed it just to do an echo. Just like the other ones. For some reason, we had echo for Mac OS. But Yeah. Last came out two years ago. Not because I I can't even believe it was that long ago, but there you go. Yeah. There it is. Changed the example for Linux so not to cause the system reboot. Yeah. Shit happens.
20:49 No kidding. Alright. Should we focus on the installation process first? How can people get Comtrya on the command line? Alright. So we will actually pop back up to this. I already have it installed in my VM, but and I did it through the curl way. So we have a couple of different ways. One, you could get the Rust tool chain, and you can cargo install it because it is on Crates.io, and you can get it that way. And that'll also give you the main branch. We do have a shell script, hosted at git.comtrya.dev that you can just pipe in the shell.
20:51 Installation Methods
21:28 With it, you can also pin a version number, so can give an exact version number if you need an older version. We also have the precompiled binaries underneath our releases section on GitHub. You can pull it from there. And then we do have it available in some package managers. Stefan has been kind enough to package it for the AUR on Arch for a long time. Michael Green, the guy I mentioned earlier who initially introduced me to Comtrya packages it for RavenPorch, which is a smaller porch tree kinda style package management system that's supposed to be cross platform.
22:10 And then here recently over the last few months, I added it to Homebrew. Nice. Yeah. I think that Homebrew approach for Mac people just makes it very, very simple. Alright. Shall we write our first manifest? Sure. May I just make a directory and call it configuration? Because there's reason you chose Debian, or is that just because you feel that, you know, Tammy, you're back with us at this point? Debian has always kinda been I kinda consider my home distro. Like, I distro hopped a lot, but Debian is kinda always where I return especially as an adult because things are just
22:27 Writing Your First Manifest
22:56 nice and stable there and, rock solid. Know what's stable? I'm a bleeding edge. Yeah. It's also what I've been, using at work whenever I deploy servers. Well, at first, I tried Ubuntu, and then I realized why I don't deploy servers on Ubuntu. And then so then I just went with Debian, and that's where I've mostly been using Comtrya is on Debian servers at work right now. Nice. Alright. So what kind of saw? What kind of man Why don't we start with just basic you know, I'm trying not to come out with too much bias because I know what Comtrya can
23:36 First Steps: Running a Command
23:43 do. But let's start with a command execution. Let's assume people just wanted, like, a YAML interface to some sort of bash script, which I would never encourage anyone to do. But command execution is probably one of the quicker and easiest ways to start doing stuff with Comtrya. Yeah. Just, like, oh. Oh, yeah. Yeah. I always forget that even after, what, fifteen years of using Linux. Let's call it main. Alright. So So this is what we call a manifest. Right? Yep. This is a a manifest, a YAML file, or it can be a TOML file. And then just kinda follow the example here.
24:35 So every manifest the basic manifest are is essentially just a collection of actions. So we prefix it at the top with actions, and then we define each action within that. So we'll just start off with a simple command dot run and make sure I have the documentation up. Because I usually always make sure I have it up so I don't mess something up. Just do a simple echo. Do that part. Perfect. Alright. And as David said, I mean, to me, I kinda consider the command dot run as, a catch all. If there's anything that Comtrya doesn't have
25:21 an action that it directly supports, there's usually always a way to get it done with the with the command dot run-in some fashion. Yeah. It's especially with the variance syntax. Like, if you need to run something differently across Linux, BSD, Mac, Windows, whatever, it's easiest to do that as a single action rather than, you know, the thing I really hated and tried to avoid as much as possible was crazy ginger templating within, say, Jamo because I think things just get messy and hacky pretty quick. Mhmm. But, of course, you can do change of template, but
25:58 there's always the escape patch. Yep. Alright. So down here, I'm gonna run it, essentially, just invoking the I can try a binary. The dash d flag gives it the directories. We're just saying the current working directory wherein is essentially the root for our manifest and then apply. And then Comtrya also allows the ability to you don't have to run all your manifests. You can selectively run them by giving this m switch. Yeah. Oh, did not get any output there. You need to add dash v. Oh, yeah. More v's. Yeah. No? Nope. I don't think it's running.
26:47 Oh, yeah. I might wanna make sure. Oh, I thought I checked this checked this yesterday. Uh-oh. Yep. If not, I guess I could do this on my Mac too. But what happens if you type type Comtrya? What does it think it is or which Comtrya? Do we have do we have anything? Yeah. Oh, yeah. It does. And let's I mean, run type space before we cat it just to be sure it's a text file. Try as hashed. Vimit? No. Yeah. Well, I primarily use Emacs, but Woah. Woah. Nano is just available. Oh, yeah. There we go. Yeah. That that's a
27:37 problem. Yeah. That is a problem. Now we get to show the installation. Yeah. Well, you quickly grab that command. I'll say happy New Year to Nuno as well. Hey. Nice to see you again. Let's see. It may we may have an issue with the installation script, At least on ARM, I will say this is Is that an ARM's what happens if you type your name dash a? Is it AMD with or ARM? It's dash a. It's ARM 64. Four. Yeah. So it should I create Pop this over so I can read it and type at the same time.
28:29 Version. And you've put dev instead of dev. Oh, yeah. That's because you're debbing mad. Pipe it through bash. That's that's the bash test condition. Alright. Maybe there's a docs error there. Yeah. There we go. And it grabbed the ARM 64 version. So, I mean, that works fine. It's just the sweet. There we go. There we go. Alright. Yeah. I'm also hoping we don't have any issues with, what was it, ganulib c that has been a rather recent issue that, at least on AMD sixty four, has kinda gotten solved. There we go. It's running Alright. Let's Comtrya. I'll see you
29:28 all later. I'm going home. Do you wanna pump a dash v onto that just so we can see the actual echo statement as well? So Comtrya tries to hide output, but it doesn't need to show you it. But you can enable deeper verbosity as you can see there. Yep. So as we can see, we have a to standard out, we have hello just as defined in our manifest. Nice. Alright. Let's push our luck. Let's install NeoVim. Alright. Let's just I I I just pecked NeoVim because you said you like Emacs, and I feel like I have to make you do the devil's
29:57 Installing Packages (`package.install`)
30:09 work. Let's keep it here. Action package dot install and make sure it's the only thing about YAML. It's a lot of times also mess up the spacing. What? What's the package name? NeoVent. Oh, double check that because I never installed it. Just NeoVent. Alright. Can you just run Uh-oh. Yeah. It's your indentation. Oh, yeah. Can you try and run nVim just so we know it's not on the machine first as well? Yeah. So your second action needs to be one space less. I think that's three in. No. Up two lanes? I think there's three spaces at the start.
31:21 Right? I believe so. One, two, three. Or is it two? There's two, but two lanes up. The package install lane, I think, is three spaces at the start. Three spaces. Yeah. At the start of that lane. Oh, here? Yeah. We'll go back one. Yeah. There we go. Okay. And then fix list and then fix the yeah. Yeah. No YAML mode here to help me. But your NeoVem is still one, two, two Oh, yeah. If you were just in Venn, this wouldn't be an issue. Or Emacs because I we just have YAML mode. Sweet. Yep. And that'll take a minute. I do
32:09 kinda wanna eventually solve that. This seems to always be the first time it runs on Debian. It always does that where it complains about the the ad repository. It's like, well, we're not mean to do anything with ad in a repository. So something I eventually wanna dig down into. But Yeah. I was curious about that too, but we do have NeoVim, so that's a pretty solid start. Clear that out. See what should we play around with. Well, I think we've got two opt I mean, we can go into whatever you want, but, you know, right now, we have a single
32:45 Structuring Manifests & Dependencies
32:50 manifest. Can you list the commands directory? What did you put in there? Oh, what did I put in there? Just main dot YAML and Yeah. You know, main dot YAML is a special name in Comtrya. It just means you can reference that manifest by the parent directory, which is commands in this case. So why don't we move the NeoVim package installed to its own manifest and then show us some sort of dependency management as well? Will do. So let's see. Directory. Because one of the really cool things about Comtrya is that under the hood, it's processing
33:35 and parsing all of this YAML or TOML and and building a directed graph. So you can actually have whatever dependency structure you need across multiple manifests, and it handles it really well. Is typing YAML why you added TOML support? No. Somebody had asked for it. I'm kinda like you. I'm not too big of a fan of TOML, but it was kinda easy enough, and somebody had asked for it. And I was like, oh, that's that's also what at at the time, it was something different for me to do. Like, I think at that point, most everything I had done was
34:19 just in the actions themselves. And I haven't really messed with anything as far as, like, how we walk through the manifest or any of the other parts of Comtrya. I was kind of just in the actions. Hadn't messed with Adams yet, really. So I was like, well, this will get me into a different part of it, and I can kinda look at it. And because Surday makes it so easy to support multiple different file formats, I was like, it's not gonna be hard. Get me into a part that I'm not used to. So That NVM should be NeoVim before you save
34:53 it. Alright. Saved. Okay. So now we've got is that software main and commands main? Yep. Or Okay. I did it as as in Okay. I can change that if we want. No. No. No. I think that that that works just fine. So why don't we update commands to depend on software? Remember, if you're watching and you have any questions and or you want some examples about some of the things Comtrya can do, now would be a good time to throw them into the chat so that we can, you know, hopefully show you something interesting. And dependencies.
35:01 Demonstrating Manifest Dependencies
35:40 Oh, I haven't had to do too much with the dependencies yet. Would it be Software.envim. Yeah. I mean, I could talk because I wrote this code, I could talk about how this works and where the inspiration came from as well. Because some people may hate the syntax, but it's actually something I stole from SaltStack. So Should we uninstall NeoVim? Yeah. Let's do it. Alright. Okay. So now we're just gonna run and try, apply commands. Right? Yeah. Alright. And there we go. Yep. See where we did the, software dot invim action first. Actually, did not know, was a dot. I
36:40 guess if you could talk a little bit about that. I I would have assumed a forward slash. I haven't had to do too much with, dependencies yet, but I need to get better at using those. No. I I need to get better at documenting. However, yeah, so there's a couple of things that are actually happening here, but Comtrya. The first one being, you know, the manifest name is the filename, except for the special case where it's main dot yaml, and then it uses a paired directory. This was also stolen. I was a huge SaltStack fan.
37:11 I used SaltStack for a decade, and it's what I used for my own dot files until I got fed up of it. SaltStack isn't really meant to run on local host, well, it can. So it doesn't do a status report and a progress report and stuff like that, things I wanted to fix Comtrya. So I stole some of the things I liked, which is the naming convention and the dependency syntax. So, you know, Comtrya supports dependency resolution from the current working directory where you run Comtrya or from wherever it finds a Comtrya dot YAML if you have one.
37:44 So you can always do absolute with software dot and then, you know, as many dot directories as you need to get to your manifest name. But you can also do local dependencies, which are dot and then if you were doing it from an the software, which again is lifted straight from SaltStack. So it's supposed to be familiar and just the syntax that I like. The manifest loader loads all of the manifests and scans for dependencies that builds that DAGs that I kinda mentioned earlier, and then they get executed in reverse order, making sure dependencies are always
38:19 satisfied before anything else. You can't do action dependencies. Manifests always run top to bottom in a linear serial order, and that's gonna make asynchronous run times in the future much easier without the DAG again too convoluted. Something that SALT stack allows is every single task within any state file can have a dependency or reference to other ones, and then you never actually know the execution order. And I wanted some degree of comprehension from just reading the manifest without going too deep. So that's why some of these trade offs were made. And, hopefully, it just makes it a bit easier to work with
38:58 as as well. We could also run Comtrya without the dash d and without the dash m. So do you wanna just run Comtrya apply? Because, you know, the dash d is the default out of the box, and you don't need dash m at all. It just run everything. Oh, yeah. Oh, I've lied to you. What's in this directory? Do a l s? Just the, two folders. Oh, that should work. Alright. I guess dash d is required. I'm I'm not sure when that changed. But just to Comtrya dash d. Apply and see if that fixes it.
39:00 Output and the Plan Stage
39:38 Oh, you need to No. Path. Yeah. Okay. Yep. Yeah. So that runs everything with depends on the resolution. So yeah. There's a really cool PR, and we'll talk about this at the end. I don't wanna get into it deep now. But I I don't think any of us are particularly happy with the output of Comtrya. We'd love to see that Yeah. Made a little better. So Yeah. There's a for debugging, it's not too bad, and how we have the output has come in handy lots of times. But there's it's not always, the best, especially, like, this portion of it. We do have
40:19 somebody who's working on progress bars. I think we also do have some places in Comtrya where we probably aren't tracing like we should. Like, sometimes we have something that's tracing as a warning when it should be tracing as information. I've kinda slowly been going through and clean up what I thought what bucket it better fit in. That's probably another little bit of a sore with the output of Comtrya is that we do have some things that I don't think get traced correctly. Yeah. Well, come on. Let's cut some slack. It's a 0.9 project. Oh, yeah. Well well, also, some of
40:57 it is just kinda difficult. Like like, there's been some that I've changed where I'm like, I kinda could go either way, but for some reason, my gut's just telling me info is correct or a warrant is correct. And there and there have been a lot of those. Yeah. Okay. Let's show a couple more examples. I've got loads in my head. I don't know if there's something you want to show, but I can keep throwing things at you if you want. One thing real quick. Probably won't necessarily be able to run an action, but one mentioned since we were messing
41:14 Exploring Conditional Logic (`where`) and Context
41:30 with the package.install is that I mentioned the term earlier was provider. Comtrya does have this concept of, like, providers, and it's not just in the package install while we use it a few other places. But the idea with the in the context of package install is sometimes you have a platform that can support multiple package managers, or maybe you run Arch, but for some reason, you want to use apps. Like, that is a possible thing to do. You can override the default selection of package manager with the provider. Actually, really two really good examples of why this might
42:16 be necessary. Actually, a few. For macOS, there's two primary package managers that people use. There's brew and mac ports. Brew is what Comtrya defaults to. But if you don't like Brew and you like Mac ports, which I've used, I've kinda gotten more into Brew, but I used to use Mac ports a lot. You can specify specifically to use Mac ports over Brew. As you can see, this has been new and was actually contributed by a coworker of mine, support for SnapCraft. So being able to use Snap packages. So if you're on, like, Ubuntu or a Linux system that has Snap and
42:53 you would rather your package come from Snap than from apps, that's possible. And then package in here from the NetBSD team is a cross platform. So you can use Package in on Linux. You can use on macOS. You can use it on free BSD, NetBSD. If you wanna use Packagen on macOS, your Comtrya will allow you to do that. You just have to specify the provider, and you gotta you gotta bootstrap Packagen on your own on macOS. Nice. I had no idea someone had to snap, but now the feudies inside me where I have to go add Flatpak and make
43:30 it better. So Yeah. That was kinda because he asked me, what was the next thing he should work on? Because, he's he's a coworker who wanted to get into open source. I'm like, well, I've got a you know, I kinda maintain a Rust project, and I can help you. So he did snap, and he did a couple of other things. I could probably stick him on flat pack. Okay. So let's let's show show off something cool, and we can integrate it to the the providers or we could do something slightly different. But let's modify our NVIM manifest.
44:03 Alright. Because I think the conditional syntax and the variance are really I don't think this is nice in other tools like this. So let's assume right. So I'm gonna take us on a round of a a weird tour here, and this doesn't make a lot of sense if you're familiar with Comtrya. So Todd's gonna be like, why are we doing it this way? Right. But we have where conditions on the manifest and on actions. Right? So let's add a where condition to this manifest that says only run on Linux, which we just do at the the top.
44:42 Where if I remember was it? You just do o s dot name equal equals, I think. But we can show people how to list that as well. So if you run Comtrya context on the command line, it'll list all of these variables that we have access to. Oh, yeah. And I guess, while we're showing this, something else that was added, and I believe it's now available in version zero dot nine dot one. We'll give you this list, but I don't think we ever necessarily showed you the values. I think, actually, Stefan implemented part of this,
45:18 and I think I just surfaced it up through a command line option maybe. I may also be just remembering, but should be able to do show values. So if you're confused, you can see what the values are. Yeah. And we have always named dot Linux. So Mhmm. Just because Stefan is watching, can we pull up one of the examples, which I think is absolutely ridiculous, but so much fun at the same time? Yeah. It's the DNS variables. I think it's under there's no context. So it must be under where maybe? Wait. If they're for No. I don't know. Search repository for
46:05 text, TXT. Maybe Stefan don't know what it is. It's just so silly but fun. Oh, that's searching. I already just did a code search rather than a file search. Oh, yeah. Shoot. I don't do that too often. At the top? Slash? Forward slash? No. But you have to be able to say dot text box. Sorry. Oh. I'm setting up a failure now. Yeah. Just click anywhere and then do slash and then type TXT. Is this yeah. I think variable include DNS. Well, that's a code. Yeah. That's code. But, yeah, if you just do a proper
46:47 yeah. That first one there, an examples directory. TXT. Yeah. And then add TXT to the search. Sorry. I'm I'm detracting now from anything useful, but this is fun. Just to type TXT and hit return. There you go. Oh, yeah. Oh, yeah. And I can try that. Yeah. So that actually does a DNS text record lookup for his domain. And so, like, if it's one of those use cases where if you want to run Comtrya in the cloud, you could actually access the, you know, the metadata on the AWS EC two instance or DNS text records to
47:34 do some sort of IP address resolution or even just pass down properties, and the machines could pick them up. And it just opened up some really weird use cases. So we've never pushed or explored, but I just think it's really it's it's just good fun. So yeah. I don't even know if his text records still exist, but it it was definitely fun when he did it. Sorry. Anyway, I I took it away from what we're actually gonna show there. So let's jump back to our terminal. I've seen that loads of times, and I've and I've always wondered. I'm like,
48:03 what what's going on there? Yeah. It's the the idea being that, you know, when you can include remote variables, this is like salt pillars for anyone that is familiar with SaltStack, and we support DNS. It could be easy to metadata. It could be postgres lookups. Like, you know, we can make anything supportive, but we just don't have the request. And I think, again, it comes down to documentation. Like, unless, you know, to go and find that that piece of code or look at that example, you wouldn't even know you could do DNS lookups within the variable context. So. Yeah. Yeah.
48:36 Well, also, that like, yeah. Of course, they exist. So And yeah. So I guess seeing that, if you notice, it says Comtrya.YAML. For people watching this, this is almost kinda like a configuration file for Comtrya. There has been kind of a cool change here. Before, I believe it's always ever looked at, like, the roots of your manifest directory. And I think there's maybe, like, one other place, but you could never specify, like, a specific like, you could have a config file just in a random place. Now as a version zero dot nine dot one, there should be a command line option that
48:41 The Main Comtrya Configuration File
49:12 allow you to say, hey. Use this specific one. Don't know if anybody will use it, but it's there if somebody needs it for some reason. If they have multiple different manifests, but or, maybe multiple different directories for some reason and but they wanna have, like, a shared config. Nice. Alright. Where were we? Oh, yeah. Where's the Linux? Let's change it to Mac OS and then just show that it doesn't run first and foremost. And that'll make sure we haven't make any mistakes. I'm showing macOS is all lowercase. It is all lower everything gets lowercase in
49:51 the context, I believe. So apply. So here we see what what partition failed. Yeah. So now if we change this to Linux, it should run again. What have we got wrong on that? Oh, I have wrapped Linux in Quartz. Oh, yeah. It's looking for a variable called Linux, is probably an empty string. And there we go. Okay. One more change for me, please. Let's add to say a similar where condition to our first action. So we're saying always run this manifest for Linux machines, but now let's only run it on Arch. Alright. Where is that? .Family.
50:44 Oh, we probably do need some documents. Is that is that variance, I think? Oh, yeah. Variance. I mean, variance and wear conditions. I mean, I'll we'll need to get into that too, but you can see the example at the bottom there. Yeah. Standard wear condition without variance, and then I'll talk about variance as well. Alright. So No. You don't need variants for this example. Where and then was it just OS.fan? Yeah. 0s.fam. Or may I can't remember. We may have to check the context. Okay. And, I mean, that shouldn't run now, so let's run it.
51:11 Action Variants for Platform Differences
51:42 Nothing to be done reconciling action. Ah, yeah. We haven't spoke about the plan stage. You wanna talk about that? The plan stage, if I recall correctly, essentially, the plan stage will take a look at the action and will determine if it can run or not, if I recall correctly. I'm I'm usually too deep into the code, not too much into the, interfaces. Yeah. We'll pop up in the manifest, and we can talk about it. Yes. So the manifest where clauses are executed before any actions are are parsed. So that says, you know, do we even need to understand these
52:31 actions? And the actions themselves, I mean, actions within Comtrya have something called a plan, which tries to determine if any of the steps need to run. Actions are actually composites of atoms. I don't know if we need to get into that, but it's a cool subsystem for building your own actions. Yeah. But this work condition actually never has to be executed because the package is already installed, and this action doesn't need to go any deeper. So it just says NeoVim exists. So we'd need to remove NeoVim again and then run it and hopefully see that the action
53:08 is skipped. Sorry. I'm I'm pushing you into parts like Comtrya. You have not explored before now. I feel bad. Oh, it's all good. Yeah. It's mostly just a lot of, like, the, wear conditions and variants. I haven't dealt too much into it. Although, I really should because the documentation probably does need to be updated. Or Oh, yeah. For sure. Like like, I think there's things like the variables we don't really have documented. So I removed it. Nothing to be done. Too much stuff. I mean, did we remove the event? We did. Yep. I wonder if it's just because the where
53:47 condition failed, and it just says nothing to be done. Maybe we don't actually specifically call it the conditional, which is an improvement. I think we should make it. That's correct. Mhmm. Let's run Comtrya context to make sure that value is what we expect, and then we can update it so that it does run. Let's see. You don't need show values. Family. Year near future. A family is your unit. Oh, distribution. Oh, yeah. Distribution. Yeah. That I wonder where we pull the family from. So I've also done some work on the one of our dependencies, the OS info.
54:31 But I don't know if that comes from OS info or not. I don't think so. Because I tried to introduce a concept to families to solve a problem. I can try it, but it's been an open pull request for, like, two years with 30 comments on it. Yeah. We should probably just fork factory at some point. Yeah. The problem I was trying to solve there was because OS info, it also gets used by cargo itself. I wanted to double check the name of that because I started talking and forgot it. Distribution. Okay. I wanna make sure it wasn't short
55:06 for distro. Some of the problem is with, like so in the package provider, it's how we determine which package provider we use. It's just this long match statement that will the more distributions we add, the longer and longer it'll be. And I was hoping to kind of shortcut it with kinda, like, this idea of, like, operating system families. Right? So we know, like, it's a pretty good heuristic to say any Debian or Debian based distribution has that. Any Arch and Arch based distribution has the ability to use Paru or Ye or Pacman. But that kinda came a little bit of
55:52 a debate, and it ended up not going anywhere. But And set it to Debian, capital d, as we want it to run this time. Debian. That was good. Installed. Alright. I'll say one more thing about that manifest, and then you can pick something else to show. But the reason variance exist is, you know, if we wanted to change the name of this package from Debbie and then Arch, say Arch is NVIM or whatever. Having two actions to me felt dirty. And, you know, that's how that's how it exists in other systems. And while we can use Jinja, and hopefully,
56:39 we never show anyone how to do Jinja and Comtrya, is that I'd also don't want that that templating approach to be how we do it. It should be more declarative. So the variance in taxes, okay, we have one multiple variance of this single action where you can have the where guard clauses, and then you can override any property on the action with the variant syntax, which is also great. You don't need to type it. We can just show it from the on the docs. I think the example there is pretty good. Alright. Let's see. The the
57:16 User and Group Management Actions
57:19 users ones might be pretty cool. Yep. Users. Alright. So something I believe it was new early last year maybe was the ability to have can try to create users. Now granted, I do not believe this works on Windows. So we do have some functionality where it's it should work on most Unix systems, but on Windows, it probably doesn't work. I believe we have this surrounded with compilation flags. But if you know you need to set up specific users or and groups to and you need to add users to groups, Comtrya has manifest actions to do that.
58:24 One caveat about this is it's not tested necessarily on everything. So if you come across, like, a Linux distribution where adding users is slightly different or a BSD or macOS, just drop an issue, and I can investigate it and fix it. Because some distros do do it a little differently, But yeah. Let's see. So let's start off by creating a group. So do group.add, and we'll just call the skip the group name of test. So try You've done a table. Good. Yeah. Oh. It's a universal law of people watching you type. No kidding. It happens at work too. Like, whenever I'm
59:28 pair programming at work, it's like, I can type just fine when I'm at my desk alone. As soon as I'm pair programming and I'm on the keyboard, it's like I can't type anything. Yep. I believe when I developed this, I was using Debian, so it should work. That actually go through. What's your fail code and users? Oh, yeah. That might be it. It's user. Yeah. Probably why. So you need to do users dot user. There you go. Alright. So oh, I need to look this up. It's been a while. You can type ID in the group name, or you can
1:00:33 just cat slash Etsy slash So there we have our test group down there. Let's see. Nano action user dot add the parameters for this guy. Get my focus back. Full name, test user, slash home slash test, username, test, and then go to shell s h. And you should also be able to use a dot group, add it in a follow-up action. Username test group test. So we've already created our group, so should just kinda skip over that because that's already done. Then we'll add a test user, set its values, and then we should be able to add
1:01:59 it to the user group. Oh, and we did have a failure. Alright. Oh, I wonder okay. This might be something I need to go back to fix. I think I made I think it has something to do maybe with the summarize. Well, I mean, the summarize is just saying it doesn't know how to describe what action it performed. I attached a few dash v's onto that, and we'll probably see an error message. User mod Okay. So it's your user mod command doesn't exist. Oh, okay. That makes Is user mod installed? Because on Debian, I don't think that's a
1:02:55 default. Yeah. It's Oh, it is. Yeah. It is. It might Scroll up again. Or Yeah. I'll just run it. Yeah. Oh, user yeah. Debian is add user instead of user oh, no. Invalid shell. See, with Linux, it's weird because you get user add or add user depending on the distro. Yeah. But that's actually complaining about invalid shell SH. I wonder if I just come here and fully path it. Why do you need to provide the shell for user add? You actually might not need to. I need to double Oh, this is for the user shell. Right? Not the location shell. Okay. Okay.
1:03:42 Gotcha. Yeah. And this may also be something of I I implement I think the first system I did was FreeBSD. So a lot of this might have come FreeBSD where whenever you add a user and it walks you through, like, its user ad script or the options, you do have to specify a shell. That kinda comes back to some of the difficulty with supporting multiple platforms is my general philosophy is try to think of, like, a base set of functionality that goes across all the platforms. Sometimes it works. Sometimes it doesn't. Yeah. Yeah. Okay. So it still failed. So
1:04:17 it might just be, something I need to dig deeper in. Exists. Yeah. You want to add a user to this group, So it might just be the way it's get assembled on Debian. Maybe the plan step doesn't check the group properly. Possibly. I wonder if I take the group out. Nope. Still fails. User add group test exists if you want to add this user to the group test. Yeah. We can fix that later. Yeah. Although, I've got a feature request for you now based on that manifest. Alright. We'll pop it back over again. Something that would be really cool. You know
1:05:04 User Management Nuances and Feature Ideas
1:05:09 how we like, we we define the user dot group, whereas that was a test group, and then we define the user username. But then we have the user group action, which actually consumes both of those properties. Instead of duplicating the test username with the test group name, it'd be good if we could reference other actions within the manifest and pull out outputs. That'd be a really cool feature. Oh, yeah. It would. There's something to get you thinking about, you know, as you ease into 2025. Oh, yeah. Just as another mention because earlier, we had talked about providers,
1:05:46 user users also use kinda like and groups use the same, like, provider syntax, and that actually may be some of the problem we're facing here is because I believe I originally wrote this on Debian, but it might have been Arch. I might have been running Arch when I did. But we just have one overarching Linux user provider, which probably is not what we should do. We should probably find a way to better separate that because some are user ads, some are user mod, try to use whatever is available on the base system, which is another thing where it
1:06:20 comes into the struggle of supporting multiple platforms is also wanna make sure whatever we use is available on the base system on a fresh installation because of, like, David's use case of he refreshes a laptop. Alright. So we've showed packages, users, groups, variants, where clauses. I mean, we're still only scratching the surface of things Comtrya could do. You know, you can do pulling GET repositories, binaries from Github. Yeah. I think maybe we could just go over the documentation for files, and then we could have a better chat about the future of of Comtrya. Yeah. I think we should also talk about
1:07:01 File and Directory Actions
1:07:03 the git too. The the git integration, especially since that has kinda changed. We'll start with files and directories. So, this is actually missing some documentation that I just discovered about a week or two ago, and I've opened up an issue. We do have more stuff available for directories that is implemented. It's just not in the documentation. But we have these file and directory options. We can do file copies, download link, remove. Unarchive is a rather newer one. We have some of the same functionality with directories. We can create a directory. We we can copy. We can delete.
1:07:42 And we have the listing. One special thing, and David will correct me if I'm wrong here. With these file actions, you need to have, like, a files directory colocated with your manifest. I hate it so much. But, yes, that is a current restriction or constraint. And the reason was is that we Comtrya will find every TOML and YAML file nested in any arbitrary depth of directories to the point where if you have YAML configurations for any other project, those couldn't be parsed and would fail the invocation. So instead, we block them out or wrap them in a files directory. I would love
1:08:25 to see that constraint lifted. It's just how do we do it in a way that a Comtrya manifest can be identified differently from any other random configuration because we do not have any discriminators that say, hey. I'm a Comtrya manifest in that YAML, which maybe we have to admit defeat at some point and make a breaking change. But who knows? I I again, I'd love to see that not be a constraint, but it is for now. Yeah. I I see where it's a pain for people. Me, personally, I haven't minded it. I've actually kinda liked it
1:08:58 where I can separate, like, using it at work. One of the big things I've really used that files directory for is Stefan, You know, like, I'll have, like, a Postgres configuration file, or I'll have a a net plan or one of those files. And it's like, it's just nice to be able to say, okay. Where are those files? Oh, they're in the files directory with where the manifest are. For me, I kinda do like it from an organizational aspect, but I see where some of the pain is. A nice separation between what are Comtrya files and
1:09:33 what are not. Yeah. It's it's it's it's not an immediate problem and not something I think we have to solve until we get more complaints. You know, I think there's only been one or two complaints about that directory needing to be a thing. But one other thing I'll call out about fails because it's pertinent to some discussions that we've been having recently. With Comtrya, we do a lot of command execution, which we do because it's very easy to, you know, elevate privileges. All file actions across Windows, Mac, Linux, and PSD are actual syscalls, which means we can't elevate privileges, which means
1:09:55 File Actions, Syscalls, and Privilege Escalation
1:10:12 eventually you're gonna wanna put something that doesn't live in your home directory and Comtrya can't handle that unless you run it as root. I mean, I don't know what the solution is there. I know we've talked about I suggested maybe going down the pool cat root. You know, we could just cheat and set UID one, the the binary, which, of course, I would never encourage anyone to do. Yeah. But there there I think there needs to like, if we're gonna say Comtrya has progressed beyond dot files to do actual system administration, at some point, we need to I mean,
1:10:41 I would say the simple dump solution would be we shell out. I mean, that's that's kinda, like, the fallback because we can always elevate whenever we shell out, which we did not show, but we can also show that too real quick. What we mean by elevate is here in command dot run, as an example, we have this, like, privileged key that you can put, and it's a true or false. It's defaulted false. But if you set it to true, we'll essentially throw a sudo or do s or run zero in front of your command So that way we can elevate privileges
1:11:16 as that command runs. The pull kit one is interesting. The only thing I think that's kinda difficult is, like, pull kit is not, in my understanding, is not available in the base of macOS. So, like, if you were to go back to macOS and try to stand up a machine from scratch from refresh install purely using Comtrya, you'll probably hit issues, which means to get around that, you would have to bootstrap Homebrew yourself. That's one thing we didn't mention. Some of the package managers, Comtrya has the logic to build a bootstrap itself. So from from a clean system, whenever
1:11:51 you do a package install, Comtrya will run a bootstrap process for Homebrew on macOS, and it should automatically configure Homebrew for you so you don't need to do that yourself. In the case of pull kit, you would have to you kinda lose that functionality to bootstrap Homebrew yourself potentially and pull pull kit because pull kit is available in homebrew or some variant of pull kit. Tricky. Right? There's never an easy solution when we start getting into these, you know, expanding the scope use cases. But they they are things, I think, you know, you and other
1:12:29 people that use Comtrya would like to see solved. But I I don't think there's a great answer. No. Other than running it, you just sudo it. Just sudo Comtrya. Right? Yeah. We just shell out. Or we shell out. Yeah. I mean Yeah. Maybe that is the answer. I mean, the fails are the only time we ever use Cisco. Maybe we should just rip it out. Yeah. Just get rid of the atoms and just have it really run the command dot execute. Yeah. Had a an underneath the hood. And, I mean, the good thing is is, right,
1:12:48 Git Integration History and Features
1:12:58 for all these actions, there is an equivalent command line program that does it. So True. True. And I'll make you start Go ahead. Alright. So the file and archive, that one is rather new. This one should allow you to be able to pull, like, a tar dot g z, and we can uncompress it for you. And I believe we can also run it as a finalizer on file dot download. I think it might be one of the few, like, legitimate finalizers we have, which something we haven't talked about initializers and finalizers. But but we should definitely make more use of
1:13:36 them. Yeah. They were I don't know. I don't know if it was me getting into over engineering land, which I am guilty of a lot. You know? I was like, I'll try it's engineered in a way that it's supposed to be easy to add actions and atoms and they're separate things and initialize some final edges with a way to modify the execution chain of the DAG that we never really built too much into, but maybe in the future. Right? I mean, if people don't know they exist, that's okay. It's only when you come to build actions
1:14:07 that those really become more important. So Yeah. We'll see. But what I'm hoping you know, we can talk about get as well. What I'm hoping that people see from all of this stuff is that, you know, Comtrya is a pretty powerful tool, and I'd love to see more people helping you out and adding actions and opening issues and stuff like that. So but before we dive into that more, why don't you go through the the Git stuff? Alright. So I guess the Git stuff needs a little bit of history. We used to use Git to RS and
1:14:38 Git sync, but it was always a problem child. A lot of it was because of OpenSSL. We would have people opening up issues, like, every few months of saying, hey. I pulled down the project, and I can't compile, Comtrya. Something's broken. Something's wrong. And it's like, do you have the open SSL development dependencies installed on your machine? No. They don't. And, yeah, and I've tried to solve it a couple of different ways. But, ultimately, earlier this year, I came down to it's a constant headache for us. Let's just rip out git completely, and there are some potential avenues.
1:15:19 But at least at the time when I was at it, it's like they're not ready yet. The big one was another one we would also get issues opened up for was how come you guys aren't using anything? You know, how come you guys aren't using Rust TLS? Well, OpenSSL is a transitive dependency. Like, Comtrya doesn't directly pull it in. It's because of the Git stuff for the most part is why we have OpenSSL. And so we would mention that, and then they would say, alright. Well, why don't you use GitOxide or Geeks, which are really kinda two
1:15:54 two of the same. One is like a library. One is the front end, which is, for those who don't know, it's like a reimplementation of Git and Rust. And I've been tracking that for close to, like, two years. I think David has too. It's like for two years, it was just never fully there. Right? It's kinda like one of those things where, from my perspective, the GetOxite project got 85% of the way there, but it's that last 15% that's, like, where the real hard work comes in. It's like my manager says from his days working at Microsoft. You know, it's it's
1:16:32 was it the first ninety percent is 10% of your time, and that last 10 is the 90% of your time when it comes to software development? Yep. But over this last fall, I went ahead and gave it a shot again with Geeks and GitOxide, and I was able to kinda bring back some of the Git functionality that we had. I don't think it's complete one to one, but at least we have something. The functionality here, you see we have actions where you can have an action to call a git clone. This one probably isn't the biggest use of
1:17:09 the git functionality. The biggest one is this may break on my machine, but I do have a little bit of an example. .Com/tc/double files. Apply. Let me take a look at that because this was just an experimentation of mine. Find something to apply. Yeah. I love that functionality. I was sad to see it be taken out, but I'm glad it's back because, you know, if you wanna run Comtrya as a cloud config scrap on a cloud server, You you don't really need to do anything except just tell it to run, and I can pull all the manifest then, which is
1:18:12 nice. Yep. Point it to a GitHub registry or GitHub repository that has it. Well, not just the cloud, but also, I imagine, for your personal machines. Right? Like Yep. You get Git, and then you just point it, and bam, you have everything. Nice. And, yeah, it'll pull it if you have it as a public repository. I haven't dived too much into what we had with GitSync, but I think GitSync handled some stuff with credentialing. So Handled, yeah, using credentials. It handled, pulling branches, revisions, tags, a whole bunch of interesting stuff. Yeah. So we don't have that yet. I
1:18:51 do plan to get back there. Right now, it's just a dumb clone on a public repo is pretty much what you're limited to. But at least we have it back, and we don't have the issues with OpenSSL. Alright. I need to ask a question now because it's staring me in the face, and it's annoying me. But can you go back to the documentation? Alright. You've got pre zero eight seven and then post, but the only thing that's different is you changed repository to repo URL. Why was that? To be honest, I think it was just
1:19:03 Git Action Parameter Change
1:19:23 as I was bringing back the actions. I it was just how I wrote it. I could change it now. But but it was like, oh oh, I also kind of at least at the time when I was writing it, yeah, it was just something I just did at at the at the moment. I wasn't really looking at how the prior struct was written. Also, kinda want a clear differentiator between the two. And, also, I think one of the things I wanted to kinda capture was, to me, with how it was before, it kinda seemed a little bit GitHub centric.
1:20:04 And I think it actually did. Like, if you didn't provide a a full URL, it would just automatically assume GitHub. And it's like, I kinda want it to seem a little bit more universal if you have, like, a public repository on, like, Bitbucket or GitLab or something. And to me, I thought that that just kinda defined it a little bit better. Nice. And, yeah, we don't append GitHub. So if you do this, it'll probably fail because it won't know to default to GitHub. So you do have to give it the fully qualified, like, URL. Alright. Makes sense.
1:20:38 Alright. I think we've covered most of the use cases. I'm gonna pop us back to biggie face mode, and we can talk about what comes next. So Comtrya's cool. There are lots of things with it. Make it a little bit easier. Yep. Try to be able to toggle to play more options. But why don't you tell us, like, do you think you will be adding or changing that and try over the next three, nine, twelve months? And what issues do you see people talking about? What changes are people looking for? Alright. So I haven't really thought far enough
1:21:11 Release Cadence and Upcoming Features
1:21:14 out for twelve months. I guess I should probably talk about kinda how I imagine releases going forward first. So in the past with Comtrya, we've kind of always just released whenever we felt it it it was kinda like the Linux kernel. Right? You know, Linus Torvald is famous for, like, version numbers don't necessarily mean anything special. He just cuts a new release whenever he feels it's ready. Right? There's no, like, strict standards. And that's kinda how Comtrya was for a while. A lot of that was because, you know, we would get busy, and we'd go months without doing anything,
1:21:45 and then we would come back, implement a lot of stuff. And that can kinda present some problems where if it doesn't look like work is getting done, the project can look dead even though maybe it's not. So with having kinda taken over more responsibility for the project, my goal is to try to do a release every quarter. So I just recently, last week or the week before, did the zero point nine point one release, and I'm looking for the next release to be sometime in spring. I'm trying to line it up with the seasons. Reason for that is,
1:22:22 one, it gives me a goal. If it's open ended, I'll just go months and months without thinking about it. Whereas if I kinda set a deadline, at least I have I I set a deadline, for myself, then I have something to work towards. And right now, I'm only kinda thinking one release ahead. But the big things I'm hoping to get done within the next release is, I have quite a few issues here, and I've been organizing them by stones. And for anybody who wants to contribute, you don't need to worry about that. That's just me organizing
1:22:55 what I think I can get done in a three month period or hope to get done, and some of it'll change because I haven't groomed it. I may have added too much stuff. But the big one is service management, which has been a topic we have talked about a lot on and off over the last two years. For those who aren't familiar, that'd be like on Linux, you're a system CTL with system d. MacOS, I'll probably do brew because brew does do service management, but could do launch d directly. But I don't see that being too
1:23:28 of or done too often. And then, of course, for the BSDs, That's probably gonna be the biggest one I plan to do during the next release, but we do have some cool issues that I'm hoping we can also get to also. There's a feature for downloading binaries directly from GitHub that I think could be useful. There was an interesting one brought up of having Comtrya be able to kinda modify and manage CronTab. Oh, nice. Yeah. That would be a pretty cool one to do. One I do hope to do so as we talked about providers earlier,
1:24:05 Feature Ideas and Design Philosophy
1:24:08 if you have different package install actions, you would have to specify that provider in each one. I would like to do something with the configuration file to kinda do, like, an overarching context so that way you could have a configuration file and say, hey. Whenever you see package install, let's go ahead and override it so we don't have to do it in every single action. Kinda like what we do with privilege escalation, which we could go back and talk on that if you want to because that's kind of interesting. Another one that I would like I don't
1:24:45 know if I'll get it done this next release, but I like to do some more research. It's an old issue that we've had for a while, and we have talked about it a little bit was adding an update flag to package install. And I think a lot of that boils down to the name is somewhat incorrect. It's not so much update. It seemed more like version pending. But that's an interesting one because this kinda goes back to kinda like not all platforms support everything. Same thing with, like, package providers. Right? Not every package not every package manager necessarily has version
1:25:19 pending. Yeah. I mean, like, there's been a lot of requests like that over the years. But in my head, it doesn't I could be convinced, but it doesn't make sense because I always feel like once you've run Comtrya, you know, at Pacman, you know, ports, whatever, they already then it's their job to maintain that state going forward. Comtrya is stateless. So it's like, why would you not just run at upgrade? Yeah. Yeah. And I can kinda see that too. Or then, like, yeah, we're using deviant on set postgres servers on deviant. They do offer different versions of postgres. Like,
1:25:59 postgres. Right? And you do that by it's like PostgresQL tag 15, and that's Postgres 15. But if you want 16, you can do tag 16. But if you just do PostgresQL, that'll pull 16. There's tech 14 for version 14. So some package managers, you you can just control it by the package name functionally. So like I said, I don't know if there'll be any movement on that one, but something I like to do a little bit more research to see if there is something. Like, I know with Homebrew having recently put Comtrya Brew, Brew formula and core can also build masters.
1:26:44 So instead of being tagged to a version, it could also do, like, the head. K. That might be kinda useful, especially for something like Comtrya where three months between releases. Right? There's stuff that may be in the documentation or stuff that's available in the main branch that just isn't released yet into a formal release. Nice. Alright. I mean, we're now at an hour and a half, So I think it's about time to wrap this up. But being that Comtrya is such a cool project and there is a bit of momentum now, you know, I'd love for us to
1:27:08 Conclusion and Call to Action
1:27:17 be able to get back together in three months and, you know, just go over the the new features and, again, talk about what's coming next so people can stay up to date with things. But, you know, before I'd just say thanks for, you know, taking a good chunk of time out of your day to sit here and, you know, check and try it with me. It's been a whole lot of fun. Uh-huh. It's no problem. Yeah. It's been fun. I also got to learn a couple new things. It's always good. I said, one one thing that's been really
1:27:44 good is that, yeah, while while you've been busy, David and Stefan still are pretty instrumental because there's parts there's parts that I still have questions about. Like, I've been all over the code base now, but there's still things I don't quite understand. And the fact that you and Stefan are kinda always there whenever I have a question and being able to answer it and help point me in the right direction has been a huge help over the past few months, especially. Well, I hope I can ship some more stuff with you, and have some more fun, and we'll take
1:28:17 it from there. But it is the end of our session. And do you have any final or last words for the audience? Other than Comtrya. Feel free to drop by, check it out, drop an issue. I do monitor it, and I do try to get back to people within a day or two. So, if you have any questions, there's also the Rawkode Academy chat, and there's also the Discord, pop in there. Feel free to ask me any questions or make any suggestions. Yeah. Go try Comtrya, and then let us know where it fails you, and we will
1:28:53 we will fix it. Thank you. Alright. Until next time. We'll see you all soon. Have a great day. Hit subscribe so you won't miss a beat. More livestream tutorials can't be beat. Keep coding. Keep learning. It's the Rawkode way. We'll catch you next time. Have an awesome day. Have an awesome day.
Technologies featured
Meet the Cast
Stay ahead in cloud native
Tutorials, deep dives, and curated events. No fluff.
Comments