Commit graph

30 commits

Author SHA1 Message Date
Ana Hobden 9ab29d5e36
Add Rosetta check for Mac (#355)
* Add Rosetta check for Mac

* Use a different, better method

* Setup sysctl error
2023-03-22 10:58:46 -07:00
Ana Hobden 371f94ba51
Set NIX_SSL_CERT_FILE in the daemon (#347)
* Set NIX_SSL_CERT_FILE in the daemon

* Fixups
2023-03-20 09:38:15 -07:00
Cole Helbling 1861d48d59
Only list changed plan settings in summary (#333)
* Only list changed plan settings in summary

* List all settings when `--explain`ing

* Sort the settings output
2023-03-13 13:30:04 -07:00
Ana Hobden 903258942c
Add more failure context / Improve error structure (#296)
* wip: add more context to errors

* Add a bunch fo context

* Repair source handling

* Add remaining contexts

* Add some context, but some of it is not right...

* Tidy up contexts properly

* Get command errors working how I want

* Remove some debug statements

* Repair mac build

* Move typetag to Action

* newtypes!

* Fix doctest
2023-03-03 14:20:17 -08:00
Cole Helbling 49154b9863
Make errors non-exhaustive (#299) 2023-03-03 20:03:51 +00:00
Cole Helbling d7c14d6695
Detect WSL1 and error (#297)
* Detect WSL1 and error

WSL1 is not supported because some things Nix relies on to work are not
available.

* Update linux.rs

* Add link to MS docs on WSL1 -> WSL2 upgrade
2023-03-03 09:49:46 -08:00
Ana Hobden 19dd7a13d4
Add diagnostics reporting (#264)
* Add diagnostics reporting

* Some tidying

* Remove injected failure

* Update URL

* Fixups

* Fix tests

* Use triples instead of architecture
2023-02-24 10:11:12 -08:00
Ana Hobden ab4c528595
Rename some of the planners (#243)
* Rename some of the planners

* Fixup Mac

* Also move actions

* Also update CI
2023-02-10 20:35:00 +00:00
Ana Hobden 2c91bea9eb
Add 32 bit support (#229)
* Add 32 bit support

* Add buildkite job for i686

* Use x86 for system on i686

* Adapt nix-installer.sh script to support i686
2023-02-06 07:50:23 -08:00
Ana Hobden d69f335703
init-less install (#188)
* wip

* Add dockerfile

* Add readme bits

* Fix logic inversion

* Relax init detection error

* Tidying heuristics

* Fix doc tests

* Mac supports start-daemon false

* Get VM tests working

* Add instructions

* Some target_os flagging

* More target flagging

* Fix lints

* Fixup more mac-only stuff

* cfg flag examples too

* Fix planner wording

* More os specific lint fixing

* More refinement on mac and the README

* Add new CI jobs to test no-daemon

* Use nix-installer-pr to point at branch

* Tests with no-init

* init/no-daemon are linux only

* nix tests support a per-distro all attribute

* Add working podman test

* Expand docker tests

* Add contributing notes

* format

* Support both podman and docker

* Update contributing

* Add Windows WSL test script for Ubuntu

* format nix tests

* More ignores to check-spelling

* Add systemd based wsl test

* We don't have root-only darwin

* Reflect review nits

* Reenable tests

* Restore mac plan

* Flag off os specific tests

* Better cfg flagging

* Remove dead comments

* Rework readme to look better with new sections

* Correct codeblock language

* Remove some warnings
2023-02-01 12:35:52 -08:00
Ana Hobden e27d01f221
Correctly expected error in default planner if nix installed (#151)
* Correctly expected error in default planner if nix installed

* fixup
2023-01-04 09:32:45 -08:00
Ana Hobden d299dbf0f2
Rename harmonic to nix-installer (#125)
* Rename harmonic to nix-installer

* Fix build

* handle nix-install.sh rename

* Forgot some things

* Fix a mistype

* Fix env var

* Fix merge change that popped up
2022-12-19 18:26:58 +00:00
Ana Hobden 1e6d7d75c9
Do SELinux checks (#123)
* Do SELinux checks

* Add improved error message with issue link

* Improve SELinux error message

* Correct lint
2022-12-19 07:30:45 -08:00
Ana Hobden c4274c93fb
Add action & Tune Tracing (#119)
* Add action

* Checkout so we have actions.yml

* yaml poking

* Handle GITHUB_TOKEN

* Don't ask github to do templating, use directives for logging

* Missing changes

* Fix build error

* Fix yaml even more

* Add shell command

* Add a wait on the socket again

* Print some debugging

* Use more correct env vars

* Correct install url logic

* Use different style for inputs

* Fix yaml errror

* Tweak around local-root

* provision nix-install.sh as well

* Use nix-install.sh path directory in NIX_INSTALL_URL

* Tweak variables to hopefully work

* Call it BINARY_ROOT instead

* Add exec output

* Set no-confirm

* no echo

* Add token to workflow

* Set no-confirm properly

* Add no-confirm back for uninstall

* Correct some env and vars

* CreateDirectory respects existing symlink

* Add a few more checks to the CI

* pass valid yaml...

* Slightly more aggressive cleanup of /nix

* Ensure steam-deck cleans /home/nix

* Add steam-deck check for persistence

* Canonicalize steam-deck persistence

* Ensure absolute path

* Inverted logic sad

* python3 on mac

* Add readme info and fix a extra-conf mistype

* Add unsaved changes

* More fine grained trace logging

* Restore spans we lost in refactor

* BuiltinPlanner can accept settings

* Reflect feedback

* Push actually working code hopefully this time

* Speeling
2022-12-16 18:55:28 +00:00
Ana Hobden dad8180985
Allow expected errors (#116)
* Move binary out of /nix if it is there during uninstall

* Add tracing

* Sorta working...

* Have expected() return an err

* Better handle expected errors during install

* Hello trailing whitespace
2022-12-12 12:20:50 -08:00
Ana Hobden 4ce8d94ac7
Create ActionError (#79)
* wip

* Fixes

* Fix a comment
2022-12-05 08:55:30 -08:00
Ana Hobden ae37842a0d
Add Steam Deck Support (#34)
* Init Steam Deck support

* Improve systemd units

* Handle stopping nix-daemon.service before stopping mount

* Better handle being in a sysext

* Add some install directions

* Add a KDE autostart script

* Tidy up uninstall

* Use stop/disable instead of disable --now

* Fixup a double-disable

* Repair some defaults

* Tidy up services

* Make ci test steam deck planner

* Delete bonus line

* Use newer image

* Get steam-deck working hopefully

* Create steamos-readonly mock

* Make stub of steamos-readonly

* Use sudo for chmod

* Attempt CI fix

* Don't add deck group

* A more clever method

* We have a new method and the CI can be cleaned a bit

* Brazenly disable sandbox on the deck ci

* Extra-conf takes vec

* Dump lsblk mount

* An even more clever method

* More debugging symbols

* More debugging symbols

* Even more debugging

* probe for issues

* Get specific with permissions and ownership (for ci)

* We are now way overboard on debugging symbols

* Specify permissions on created home stub

* Allow specifying persistence

* Cleanup debugging bits

* Fixup persistence path

* Work out some better linking in units

* units don't need executable

* Tidy

* Delint

* Remove a note from readme

* Github actions seems to have build the wrong checkout?

* Doctest repair

* Don't create directory twice

* Restore missing doc comments

Co-authored-by: Cole Helbling <cole.e.helbling@outlook.com>
2022-12-02 07:31:15 -08:00
Ana Hobden c39bf0a510
Flesh out docs and tidy up public API substantially (#67)
* Make plans versioned

* Delint

* speeeeeeeeling

* remove file that was dead

* Flesh out docs and improve public API

* Speeling

* Fixups

* Fix doctests

* Do a better job with actionstate

* Add some more docs

* Fix doctest

* Make CLI stuff optional

* Touchup

* Speeling
2022-11-28 22:57:35 +00:00
Ana Hobden 7cc71f1ccd
Make plans versioned (#62)
* Make plans versioned

* Delint

* speeeeeeeeling

* remove file that was dead
2022-11-25 11:46:38 -08:00
Ana Hobden 72d3fcd942 Detect if plan already done 2022-11-08 10:18:05 -08:00
Ana Hobden e57311a807 Install can detect existing /nix/receipt.json 2022-11-08 09:58:53 -08:00
Ana Hobden eb1d8215f3 Improve planner and plan output 2022-10-28 12:44:07 -07:00
Ana Hobden 92f6a4e2b7 Cleanup BoxableError location
Signed-off-by: Ana Hobden <operator@hoverbear.org>
2022-10-27 08:38:21 -07:00
Ana Hobden f49c155117 Ensure Planners and Actions can be created externally
Signed-off-by: Ana Hobden <operator@hoverbear.org>
2022-10-26 15:13:42 -07:00
Ana Hobden cc1cbe109a Box up errors, dyn Actionables
Signed-off-by: Ana Hobden <operator@hoverbear.org>
2022-10-26 14:14:53 -07:00
Ana Hobden 706af47714 Tidy up some planner api
Signed-off-by: Ana Hobden <operator@hoverbear.org>
2022-10-26 09:27:50 -07:00
Ana Hobden 16acc1fe6c Rework planners to support custom args 2022-10-25 11:57:09 -07:00
Ana Hobden 8924bf5cb7 Hobbling along 2022-10-24 16:16:18 -07:00
Ana Hobden 64e7423a0a Explore planner pattern using steam deck example 2022-10-17 12:19:07 -07:00
Ana Hobden 144af153f6 Support different planners 2022-10-14 15:14:03 -07:00