Commit Graph

2304 Commits

Author SHA1 Message Date
James Shubin
6ac72974eb lang: ast, interfaces: Move textarea to a common package
We're going to use it everywhere. We also make it more forgiving in the
meanwhile while we're porting things over.
2025-06-06 01:00:11 -04:00
James Shubin
4189a1299a lang: ast: Add scope feedback for classes
We did this elsewhere for functions, let's add classes too.
2025-06-06 01:00:11 -04:00
James Shubin
dcd4f0709f lang: ast: Provide better error reporting for scope errors
Print these file and line numbers when we can!
2025-06-05 23:00:56 -04:00
James Shubin
75bafa4fd3 mcl, docs: Use the less ambiguous form of the import
Update the style guide as well!
2025-06-05 22:47:38 -04:00
James Shubin
e5ec13f592 modules: misc: Add a class to install a copr repo 2025-06-05 22:47:38 -04:00
James Shubin
1a0fcfb829 modules: misc: Use the less ambiguous import name 2025-06-05 22:34:33 -04:00
James Shubin
ba86665cbb misc: Rename for consistency 2025-06-05 22:34:29 -04:00
James Shubin
301ce03061 misc, setup, util: Add a ulimit
I think this gives us the ability to open more files.
2025-06-05 22:34:29 -04:00
James Shubin
650e8392c5 golang: Tidy mod file
I ran go mod tidy.
2025-06-05 21:46:28 -04:00
James Shubin
d7534b2b3b golang: Update go.mod to avoid tidy warnings 2025-06-05 21:45:06 -04:00
James Shubin
3b88ad3794 lang: core: os: Add a modinfo function
Not sure if this will need renaming, but might be a useful family of
functions.
2025-06-05 21:40:19 -04:00
James Shubin
499b8f2732 lang: funcs: dage: Make error clearer
The implementation of the specific function is sending a nil value,
which is not allowed. This is a bug in the code of that function.
2025-06-05 20:36:15 -04:00
James Shubin
ac3a131a9f modules: meta: Improve firewall rules for our router 2025-06-05 14:47:46 -04:00
James Shubin
a72492f042 modules: meta: Move router to networkd
I can't get NetworkManager working properly in parallel to wireguard. I
get an extra route added and it breaks the tunnel. No idea why. The
networkd equivalent seems to just work.
2025-06-05 14:47:46 -04:00
James Shubin
c51a55e98a modules: misc: Add networkd helpers 2025-06-05 14:47:46 -04:00
James Shubin
892fd1e691 modules: misc: Add a network manager dhcp interface 2025-06-05 14:47:46 -04:00
James Shubin
23aa18d363 modules: shorewall: Refactor to allow bulk rules
Very useful for brownfield deployments where we're migrating a ton of
rules over.
2025-06-05 14:47:46 -04:00
James Shubin
d14930ef28 lang: core: embedded: provisioner: Don't provision to USB disks
This should hopefully skip over any USB drives. Of course if we actually
want to provision to a USB drive, then we'll have to add a feature flag
for that.
2025-06-05 14:47:46 -04:00
James Shubin
81063ae6df etcd: ssh: Reconnect on SSH failures
If the SSH connection dies, the dialer can now reconnect that portion.
2025-06-05 14:47:46 -04:00
James Shubin
f42daf4509 etcd: ssh: Improve logging to be less misleading 2025-06-05 14:47:46 -04:00
James Shubin
1caf6fb3bf etcd: ssh: Pass through the ctx into the SSH dialer
I hope I did this correctly.
2025-06-05 14:47:46 -04:00
James Shubin
16ade43caf engine: Rename world API and add a context
We want to be able to pass ctx through for various reasons.
2025-06-05 14:47:46 -04:00
James Shubin
99d8846934 engine: resources: Remove env
The nix people want this sometimes, and don't in others ;)

Karpfen, you now owe me a $beverage =D
2025-06-05 14:47:09 -04:00
Lourenço Vales
2d78dc9836 modules: contrib: Add cryptpad module
This is a module to deploy cryptpad locally - as it is, this is only
intended for dev purposes, not for production environments
2025-05-26 14:28:33 +02:00
James Shubin
b85751e07e setup: Add the ssh url arg to the setup utility 2025-05-26 02:26:32 -04:00
James Shubin
0fd6970c0a engine: resources: The http server flag res should autogroup
If we want to receive more than on flag (key) value, then these
obviously need to autogroup together, because it's the same http server
request that comes in and which should be shared by everyone with the
same path.
2025-05-25 04:46:34 -04:00
James Shubin
936cf7dd9d engine: graph: autogroup: Ensure we sort correctly
This should ensure this sort order of longer thing first, when running
the algorithm. We want to autogroup two or more http:server:flag
resources together first, before the whole grouped resource gets pulled
into the http:server one.
2025-05-25 04:21:44 -04:00
James Shubin
fd5bc63293 engine: traits: Allow self-kind with hierarchical grouping
Not sure why I was blocking this previously, perhaps there was no use
case, and I was trying to ensure there wasn't accidental, unwanted
grouping? Perhaps I wanted to improve performance? In any case, let's
turn this off for now, and check for bugs.
2025-05-25 04:19:38 -04:00
James Shubin
be4cb6658e engine: graph: Simplify the Send/Recv code
This code might be slightly redundant, so simplify it. If something went
wrong, this will be the commit that did it, but it seems relatively
safe.
2025-05-25 04:18:26 -04:00
James Shubin
efff84bbd4 engine: graph: autogroup: Print these errors when debugging
This gives important clues as to why something isn't grouping as
expected. Show them if needed.
2025-05-25 03:48:57 -04:00
James Shubin
74f36c5d73 engine: resources: Add some compile time checks for groupers
These can "break" silently and not autogroup if we change the resource
and it no longer fulfills the interface. Add this compile time check to
prevent that.
2025-05-25 03:47:47 -04:00
James Shubin
b868a60f69 engine: resources: Simplify the Watch loop
I had some legacy unnecessary boolean for sending everywhere. Not sure
why I never re-read it, it's so easy to just copy and paste and carry
on.
2025-05-25 02:12:14 -04:00
James Shubin
f73127ec23 engine: resources: Make error not ambiguous
The same text exists elsewhere.
2025-05-25 01:42:41 -04:00
James Shubin
654e958d3f engine: resources: Add the proper prefix to grouped http resources
Resources that can be grouped into the http:server resource must have
that prefix. Grouping is basically hierarchical, and without that common
prefix, it means we'd have to special-case our grouping algorithm.
2025-05-25 01:40:25 -04:00
James Shubin
1f54253f95 engine: resources: Add a trim field to line resource 2025-05-25 01:40:21 -04:00
James Shubin
2948644536 lang: ast: Remove the double dash
Not sure why this is here?
2025-05-25 01:17:28 -04:00
James Shubin
d2403d2f0c etcd: client: str: We do not want the prefix match
This was a likely copy+pasta error, since we match precise strings here.
If we had two similarly prefixed strings, we'd have an error.
2025-05-25 01:17:28 -04:00
James Shubin
876834ff29 lang: core: fmt: Catch printf edge case 2025-05-25 01:17:28 -04:00
James Shubin
861ba50f9c engine: resources: Add a ui redirect
I always forget the /index.html part so make it easier!
2025-05-15 02:52:57 -04:00
James Shubin
43492a8cfa make: Add missing clean target for wasm 2025-05-15 02:41:58 -04:00
James Shubin
287504cfa8 engine: resources: Add missing struct tags to kv 2025-05-15 01:46:03 -04:00
James Shubin
0847b27f6a modules: misc: Add a pattern for systemd daemon reload
It would be really nice if systemd actually had an API for getting
events on this.
2025-05-14 21:21:27 -04:00
James Shubin
aa4320dd5f modules: misc: Add some authorized key work
More testing and features are needed, but this is a good start.
2025-05-09 04:11:04 -04:00
James Shubin
7c5adb1fec lang: core: net: Add a helper to return the network ip 2025-05-09 02:49:02 -04:00
James Shubin
20e1c461b8 lang: core: embedded: provisioner: Update import style 2025-05-09 02:48:51 -04:00
James Shubin
e9d485b7f6 lang: ast, core: Add some safety checks
I don't think I'm hitting these, but good for debugging.
2025-05-09 01:08:12 -04:00
James Shubin
e86d66b906 engine: resources: Avoid double slash on error
Errors will include a second slash if this ends with one. Might as well
clean it to avoid the semblance of a bug.
2025-05-09 00:00:46 -04:00
James Shubin
9a63fadfbd engine: resources: Rename var
So it doesn't conflict with "path" import.
2025-05-08 23:16:57 -04:00
James Shubin
7afa372765 engine: resources: Let the user race me
If a user is racing the file resource, don't error permanently, just
skip the file that vanished, and move on with your life.
2025-05-08 23:11:51 -04:00
James Shubin
fddebb2474 engine, lang: core: Match exported resources properly
I inverted the logic for complex setups and forgot to handle the zero
cases. I also didn't notice my loop continue error. This cleans all this
up so that we can have proper exported resource matching.
2025-05-08 22:29:03 -04:00