Daniel Barlow
f57997c605
remove explicit MTD_BLKDEVS, is selected by MTD_BLOCK
2023-09-30 21:45:50 +01:00
Daniel Barlow
3c483ebd9a
set PARTITION_ADVANCED only in ramdisk module
2023-09-30 21:29:12 +01:00
Daniel Barlow
a30b658999
remove CMDLINE_PARTITION, we don't need it
...
(at least, I think we don't)
2023-09-30 21:20:29 +01:00
Daniel Barlow
1ec7fcc197
remove MTD_CMDLINE_PARTS from per-device config
...
it's enabled in modules/ramdisk, which is required by
flashimage and tftpboot
2023-09-29 21:00:25 +01:00
Daniel Barlow
f9f934b40c
spell GL.iNet consistently in docs
2023-09-28 23:22:54 +01:00
Daniel Barlow
e3c8ab351e
fix sphinx warning
2023-09-28 12:19:48 +01:00
Daniel Barlow
7e13eda490
add hardware device descriptions to doc
...
most of the text is recycled and follows no particular format
2023-09-28 12:17:30 +01:00
Daniel Barlow
3a2f074199
disable 4k flash erase blocks everywhere
2023-09-27 22:10:17 +01:00
Daniel Barlow
74f4e0a2f3
fiddle with manual layout
2023-09-27 13:44:26 +01:00
Daniel Barlow
9133475103
update tutorial discussion of liminix-rebuild
2023-09-27 11:05:06 +01:00
Daniel Barlow
abd01a7809
apply mtdpslit patch only for openwrt kernel
...
it doesn't apply to mainline because there's no mtdsplit
in mainline
2023-09-26 18:40:22 +01:00
Daniel Barlow
d0c2b3b274
explain the "demo" example
2023-09-26 18:24:40 +01:00
Daniel Barlow
dfe7228b99
fix jffs2 mtd partition splitting on little-endian CPU
2023-09-26 16:43:03 +01:00
Daniel Barlow
ab147abd9b
less padding in firmware.bin
...
we only need to align to erase block size, which may be
less than the 128k previously hard-coded
2023-09-26 16:43:03 +01:00
Daniel Barlow
bca0c9b26b
gl-mt300a use regular-sized flash erase blocks
2023-09-26 16:43:03 +01:00
Daniel Barlow
c59a228955
this is the dhcp6c service we want
2023-09-26 16:43:03 +01:00
Daniel Barlow
1673a71831
WIP third example
2023-09-24 23:11:28 +01:00
Daniel Barlow
94e51db649
tests: use run.sh instead of calling run-liminix-vm directly
...
this makes it easier to run tests on aarch64 where
qemu wants an Image file instead of a vmlinux
2023-09-24 00:24:48 +01:00
Daniel Barlow
3205a38ac9
mac80211 use correct arch
2023-09-24 00:17:32 +01:00
Daniel Barlow
119d6ad379
pkgconfig is now pkg-config
2023-09-21 12:25:35 +01:00
Daniel Barlow
8d356890b0
add aarch64 to CI
2023-09-21 00:00:21 +01:00
Daniel Barlow
be22fbbb0a
bootable aarch64 liminux with qemu
...
I may have broken the run-liminix-vm command a bit for MIPS due to
necessary changes in how we pass the command line. If CI isn't green
for this commit and youre trying the worked examples, I suggest
reverting to the commit before this one.
2023-09-20 22:55:51 +01:00
Daniel Barlow
9f87fd8625
import arch in qemu device config
2023-09-20 21:31:38 +01:00
Daniel Barlow
3a3ee8bbbd
fix CI doc error
2023-09-20 21:31:38 +01:00
Daniel Barlow
381730d081
fix CI flashimage error
2023-09-20 21:31:38 +01:00
Daniel Barlow
57eb55de58
found another mips-vm to rename
2023-09-20 19:13:04 +01:00
Daniel Barlow
4389fa15f7
rename mips-vm as run-liminix-vm
2023-09-20 18:33:20 +01:00
Daniel Barlow
4f29bdd3ed
detect arch in kernel and uimage
...
also move kernel builder to pkgs/
FIXME we need to straighten out the mess in calling
dtb.nix/uimage.nix
2023-09-20 18:26:33 +01:00
Daniel Barlow
f1c04c7979
extract mips kernel options to module
2023-09-20 17:50:21 +01:00
Daniel Barlow
f75995e895
introduce modules/arch/{mipsel,mipseb}.nix
...
for settings that are common to all mipse[lb] but would not be shared
with e.g. aarch64 or x86
2023-09-20 17:30:05 +01:00
Daniel Barlow
12b9feb8ee
using openwrt mtd command, advide erase before writing
2023-09-18 10:59:55 +01:00
Daniel Barlow
b3a7a2246d
tutorial: move the warning nearer to the decision point
2023-09-17 21:53:15 +01:00
Daniel Barlow
6674344021
don't end chapter with ellipsis
2023-09-17 21:47:09 +01:00
Daniel Barlow
c81ee62374
doc: proofread admin section, add link to TFTP
2023-09-17 21:44:32 +01:00
Daniel Barlow
dd0b1734c1
how to write a module
2023-09-17 21:32:22 +01:00
Daniel Barlow
0a2588013a
include generated module options
2023-09-17 17:47:04 +01:00
Daniel Barlow
71b583a756
copy "how to flash" from the old docs
2023-09-17 17:36:02 +01:00
Daniel Barlow
98e7536e59
think
2023-09-17 17:03:56 +01:00
Daniel Barlow
e72d78ab64
restore intro
2023-09-17 17:03:56 +01:00
Daniel Barlow
17035ca3b7
outline of the missing doc sections
2023-09-17 17:03:56 +01:00
Daniel Barlow
dece70b336
link to ADR
2023-09-17 17:03:56 +01:00
Daniel Barlow
50ea144dec
mention service dependencies
2023-09-17 17:03:56 +01:00
Daniel Barlow
fc84435985
improve syntax blah
2023-09-17 17:03:56 +01:00
Daniel Barlow
06b725cb77
document the module-based-services decision
2023-09-17 17:03:56 +01:00
Daniel Barlow
c74543c4ff
doc: how to define an s6 service
2023-09-17 17:03:56 +01:00
Daniel Barlow
54526c1e11
start writing configuration guide
2023-09-17 17:03:56 +01:00
Daniel Barlow
f81aa54444
rename file
2023-09-17 17:03:56 +01:00
Daniel Barlow
56261f77b0
add example with real hardware
2023-09-17 17:03:56 +01:00
Daniel Barlow
8600dfc8cf
proofread v2
2023-09-17 17:03:56 +01:00
Daniel Barlow
bb280c6d97
rename qemu example
2023-09-17 17:03:56 +01:00
Daniel Barlow
b7e805c97f
connecting a client to hellonet
2023-09-17 17:03:56 +01:00
Daniel Barlow
9223fa7ec4
first proofreading pass
2023-09-17 17:03:56 +01:00
Daniel Barlow
0f31afee2b
hellonet: set password for root
...
otherwise incoming ssh gets a bit fraught
2023-09-17 17:03:56 +01:00
Daniel Barlow
98c63e7498
hellonet: don't run ntp
...
it's a bit pointless when there's no connectivity to
any ntp server
2023-09-17 17:03:56 +01:00
Daniel Barlow
c6faf88dd1
doc WIP: build "hello net" example
2023-09-17 17:03:56 +01:00
Daniel Barlow
35c7f1643f
change defaultOutput for hardware devices to flashimage
...
if you're using tftpboot you probably know what you're doing
2023-09-17 17:00:45 +01:00
Daniel Barlow
70fb9f86d3
mt300a vlan interface services depend on primary
2023-09-17 17:00:38 +01:00
Daniel Barlow
b36272f99e
add outputs for vlan service
2023-09-17 17:00:31 +01:00
Daniel Barlow
0abe4f96a7
ssh ensure we create /run/dropbear
...
this is required if we don't have persistent store (jffs2)
2023-09-17 17:00:26 +01:00
Daniel Barlow
f7b30939b5
remove service-state when service exits
2023-09-13 22:49:00 +01:00
Daniel Barlow
4fd1b5f08b
er, "input" != output"
2023-09-13 18:01:50 +01:00
Daniel Barlow
106a429b3d
odhcp-script only write addresses if there are any
2023-09-13 17:51:07 +01:00
Daniel Barlow
b3e505abf4
anoia.system print command if it failed
2023-09-13 17:50:40 +01:00
Daniel Barlow
92e107d77c
update acquire-delegated-prefix to use svc.events
2023-09-13 17:49:57 +01:00
Daniel Barlow
fa040a194c
acquire-wan-address remove boundness checking
...
if we're unbound then the script will be called with
empty ADDRESSES and so the usual case will handle this fine
by removing all the previosuly set addresses
2023-09-13 13:17:58 +01:00
Daniel Barlow
3bdb7754d3
replace var/each with accumulate
2023-09-12 20:55:08 +01:00
Daniel Barlow
8f97c5bf3c
anoia service :events method behaves as iterator
2023-09-12 20:46:52 +01:00
Daniel Barlow
7904c6bfe9
anoia users now need lfs
...
... and we need to figure out how to do transitive
dependencies, because this is not a great experience
2023-09-12 18:46:04 +01:00
Daniel Barlow
74b8c98aaf
kludge fix openssl build
2023-09-12 18:44:43 +01:00
Daniel Barlow
0a737c62cd
convert acquire-wan-address to writeFennel
...
this means we can get rid of the inelegant environent variable
check at the bottom of the file
2023-09-12 17:51:00 +01:00
Daniel Barlow
343d3b6508
writeFennel is writeFennelScript with knobs on
...
The second parameter is now an options attrset, wherein we will pile
all kinds of cool stuff.
Right now the only cool bit is `mainFunction`, which allows you to
compile a fennel module into a lua script and name the function that
should be executed when the script runs. This makes it easier to
write testable Fennel code, because the test script can require the
module and call stuff in it.
2023-09-12 17:45:18 +01:00
Daniel Barlow
96e19767e9
odhcpc-script don't require fennel at runtime
2023-09-12 17:39:06 +01:00
Daniel Barlow
6f2389dd75
la la la
2023-09-12 17:38:18 +01:00
Daniel Barlow
d49cbbb8ed
test for acquire-wan-address
2023-09-11 00:07:49 +01:00
Daniel Barlow
7683ed69de
acquire-wan-address uses parsed addresses from odhcp
2023-09-11 00:07:11 +01:00
Daniel Barlow
3ff55d3aad
odhcp-script: unique subdirectory names for each parsed address
2023-09-10 12:15:34 +01:00
Daniel Barlow
22275f311c
anoia: add simple hash function and base64 encoder
2023-09-10 12:14:39 +01:00
Daniel Barlow
870da62a1e
anoia.svc outputs may be directories (read as table)
2023-09-09 00:30:02 +01:00
Daniel Barlow
0312f7a999
fennelrepl look for .fnl before .lua
...
this means fennelrepl in nix-shell will prefer local
source files to generated lua files, making it easier
to change library code without restarting the shell
2023-09-09 00:11:35 +01:00
Daniel Barlow
9dd3cf23b4
anoia.fs.mktree replaces mkdir
...
This uses lfs to make the tree in-process instead of
shelling out to the mkdir command
2023-09-08 21:17:42 +01:00
Daniel Barlow
4e9227dff3
move rmtree to anoia library
2023-09-08 21:03:18 +01:00
Daniel Barlow
eaa45906ff
fennelrepl runs with --correlate
...
this is so that error message line numbers match up
2023-09-08 21:02:26 +01:00
Daniel Barlow
7fc5d2934d
set FENNEL_PATH using absolute paths
2023-09-08 21:01:39 +01:00
Daniel Barlow
12e25722fa
odhcp-script: delete stale dirs from previous runs
...
This requires adding LFS as a dependency because native Lua has
no way to iterate a directory, but it seems to be Not Huge and
hopefully we'll have other uses for it
2023-09-08 20:48:01 +01:00
Daniel Barlow
09fe21260e
rename fn
2023-09-08 20:48:01 +01:00
Daniel Barlow
4bd3ccc8fd
inline write-{addresses,prefixes}
2023-09-08 20:48:01 +01:00
Daniel Barlow
3e163d4253
remove unused fn
2023-09-08 20:47:55 +01:00
Daniel Barlow
9487cb2567
DRY near-duplicate code between parse-{addresses,prefixces}
2023-09-08 20:47:55 +01:00
Daniel Barlow
907a9de773
update
2023-09-08 20:47:55 +01:00
Daniel Barlow
b25103be2e
test script for odhcp6-script
2023-09-08 20:47:55 +01:00
Daniel Barlow
353a199ab2
odhcpc script: parse ADDRESSES and PREFIXES
...
so downstream doesn't have to
2023-09-05 22:42:25 +01:00
Daniel Barlow
91e957ced7
static leases for rotuer
2023-09-04 23:07:13 +01:00
Daniel Barlow
899f096346
dnsmasq static hosts defaults to empty attrset
2023-09-04 23:02:17 +01:00
Daniel Barlow
0cf4733327
add placeholders for missing module docs
2023-09-04 22:19:22 +01:00
Daniel Barlow
0a6af46364
support dhcp static leases
2023-09-04 22:08:07 +01:00
Daniel Barlow
a24c2a23a0
whitespace
2023-09-04 22:06:15 +01:00
Daniel Barlow
9e52faa0b6
remove unused imports
2023-09-04 22:05:42 +01:00
Daniel Barlow
3bdc986dd7
extract "mount filesystem" to module
2023-09-04 21:17:52 +01:00
Daniel Barlow
83092b7b73
add watchdog service
2023-09-02 17:28:40 +01:00
Daniel Barlow
6805e0090d
working down the TODOs
2023-09-01 17:57:22 +01:00