Skip to content

Almost at v1 #1

@mhfowler

Description

@mhfowler

I think this repo is almost at parity with the original peach-config in python now.

By making a cmd utility, it ended up being quite similar to python, and I was able to do a lot of regex find and replace while I was re-writing which made it much quicker, plus of course still some tinkering needed and doing things differently in the two languages.

As there were command line arguments that effect the control flow, it ended up making more sense to me to just re-write entirely in rust like this, as opposed to invoking "bash scripts" from rust (because then I would have also needed to pass CLI arguments to the bash scripts, and additionally parse the CLI args in bash as well as rust). I think I like how it looks in rust anyway, and I like that it will be very extensible in the future, and has uniformity with the rest of the codebase. For instance, we could even decide to refactor something and move it out of peach-config and into peach-lib or a different microservice etc. and because its all rust, it wouldn't be that much of a hassle, which I think is a good thing for the future.

I was hoping to have it all wrapped up with perfect parity by the end of this week (arbitrary deadline I made for myself), but there are still a couple outstanding issues:

  1. I commented out the line about kernel.printk as it was throwing an error. I'm not sure the source of this error or how to fix it but thought maybe you would have some ideas? Something to note is there was also a kernel update since the last time I built the image, to vmlinuz-4.19.0-17-arm64.
    [2021-07-24T02:11:46Z ERROR peach_config] peach-config encounter an error: "["sysctl", "-w", "kernel.printk=4 4 1 7"]" returned an error. sysctl: cannot stat /proc/sys/kernel/printk: No such file or directory
  2. with that line commented out, the setup script runs fully to completion as before. When I log into the pi, it connects to the internet like before, but it is not resolving DNS correctly. I am not sure what the issue is. Maybe something with /etc/resolv.conf ? Thought you might have some ideas on this one too, or we could debug together.
  3. need to finish add CLI args for the peach-config update command
  4. need to add some more comments and documentation

cc @mycognosist

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions