aboutsummaryrefslogtreecommitdiff
path: root/src/main.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.rs')
-rw-r--r--src/main.rs20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/main.rs b/src/main.rs
index e7a11a9..fcea38d 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -1,3 +1,23 @@
+// Reboot and rollback logic
+// /data/update does not exist? => MONITOR
+// CHECK:
+// Connection to tcp!ipv4.google.com!80 unsuccessful? => FAIL
+// Connection to tcp!ipv6.google.com!80 unsuccessful? => FAIL
+// No connection from updater? => FAIL
+// => MONITOR
+// FAIL:
+// If 5m passed since first CHECK? => TIMEOUT
+// Wait 30s => CHECK
+// TIMEOUT:
+// Trigger rollback (can use /data/admind.passwd) => REBOOT
+// MONITOR:
+// Connection to tcp!ipv4.google.com!80 unsuccessful? => DROPOUT
+// Connection to tcp!ipv6.google.com!80 unsuccessful? => DROPOUT
+// Wait 5m => MONITOR
+// DROPOUT:
+// If DROPOUT for 1h? => REBOOT
+// Wait 5m => MONITOR
+
fn main() {
println!("Hello, world!");
}