Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
    Rushmore Mushambi
    @rushmorem
    I can effectively create infrastructure that's smart enough to manage itself.
    Pete Hayes
    @petehayes102
    Hehe. That's actually how I came up with the name - "INTElligent infrastruCTURE"
    Rushmore Mushambi
    @rushmorem
    Oh, I see! Good job. It's an awesome name. I wondered a few times what it meant but even then it did sound cool :)
    Quick question... Even though NixOS doesn't have first class support right now, there is nothing stopping me from using Command to run any commands I want on it, right?
    Pete Hayes
    @petehayes102
    Hrm, that's an interesting one. I don't think so. Let me consult the code for a minute.
    Actually no, I think you'll run into trouble, though you could fake it!
    Check out <api>/src/target/linux.rs:318
    I hate the way the target abstractions work. So bad. Anyway, the OS fingerprinting is really trivial, so you could touch /etc/cents-release and trick Intecture to thinking you're CentOS
    or whatever platform you want to imitate...
    *centos-release autocorrect...
    Rushmore Mushambi
    @rushmorem
    I see. Thanks, that's very useful to know. Let me check that source file.
    Rushmore Mushambi
    @rushmorem
    Yeah, I think I can just fake this for now.
    Pete Hayes
    @petehayes102
    :+1:
    Rushmore Mushambi
    @rushmorem
    I'm interested to know why you chose to do it like this though. Why target each distro directly?
    Pete Hayes
    @petehayes102
    Most of it is actually generic, but I needed a way of isolating the quirks of each OS. There's always stuff that is done slightly differently.
    Basically it's a structure that I came up with as I was still designing Intecture, then as I got more experience with it, I found a better way of doing it. It's just going to be a bit time consuming to rewrite the target stuff
    Rushmore Mushambi
    @rushmorem

    I understand that but much of the things are done exactly the same way especially on Linux. For example there isn't much difference between Debian and Ubuntu.

    My point is, why not make Command just execute any command sent to it directly, much like the std lib's Command so that it can run on any OS and distro. Everything else can then start building on top of that.

    Pete Hayes
    @petehayes102
    True. I want to move to a "providers" model, where for things like Command we have a generic provider, but for things like Package we have multiple providers.
    Rushmore Mushambi
    @rushmorem
    The target traits can then take care of the nuances between different systems.
    Pete Hayes
    @petehayes102
    Yep. I am pretty immature on Rust traits. I know they could be used in a much smarter way.
    Rushmore Mushambi
    @rushmorem
    I wouldn't say that. You have done some amazing work so far :)
    Care to share your plans on the next design? I have some ideas as well. Maybe we can work together on this...
    Pete Hayes
    @petehayes102
    Thanks mate :) I really appreciate the encouragement. I'm off to bed now but feel free to keep posting stuff and I'll pick it up in the morning.
    Rushmore Mushambi
    @rushmorem
    OK, thanks. About time I went to sleep as well LOL.
    Pete Hayes
    @petehayes102
    Yeah definitely. I have a tonne of stuff for the immediate and longer term. I am working on business development at the moment (hence why I'm not keeping up with tickets) but will put together a roadmap and share that
    I would definitely appreciate input on design and future direction
    I'll chat to you soon mate!
    Rushmore Mushambi
    @rushmorem
    OK, see you then.