Files
visa/Cargo.toml
T
grabowski a2cedcdd7e
CI / secret scan (push) Successful in 5s
CI / fmt, clippy, tests (push) Successful in 39s
Phase 5: the Immigration Bureau's forms, filled in from the records
A Forms tab on each person fills in TM.7, STM.2, STM.9, STM.11 and STM.1
for an extension of stay, TM.47 for a 90-day report and TM.8 for a re-entry
permit. The Bureau's blank pages (forms/, with their sources and checksums)
go unchanged into a new PDF, and the values are written on the dotted lines
in Sarabun; boxes are ticked and the title circled where a form asks.
scripts/gen_layout.py measures the blanks into src/papers/layout.rs.

The tab says what would stay blank and links to where it is added. What only
the application says (the date, the office, the reason, the days, a trip) is
carried in the links and never stored. The extension's five forms also come
in one PDF. Opening or downloading a form is audited as entity "form" with
the forms' codes, never their values.

Migration 0005 adds what STM.1 and STM.11 ask of the company (capital,
revenue, equity, staff, a coordinator), a work permit's salary and contract
dates, and where an arrival came from. The Nix package now takes forms/.
2026-11-18 12:30:03 +07:00

61 lines
1.9 KiB
TOML

[package]
name = "visa"
version = "0.1.0"
edition = "2024"
rust-version = "1.95"
description = "visa.buildfor.life: immigration records, deadlines and extension packs for foreigners in Thailand"
publish = false
# Integration tests are one binary: tests/main.rs declares every tests/*.rs
# as a module, so the suite links once.
autotests = false
[lib]
doctest = false
[[bin]]
name = "visa"
path = "src/main.rs"
test = false
[[test]]
name = "integration"
path = "tests/main.rs"
[dependencies]
anyhow = "1"
axum = { version = "0.8", features = ["multipart"] }
base64 = "0.22"
chrono = { version = "0.4", default-features = false, features = ["clock", "std", "serde"] }
form_urlencoded = "1"
krilla = { version = "0.8", default-features = false, features = ["pdf", "simple-text"] }
minijinja = "2"
# The login service's certificate is checked against the system's CA bundle
# (native roots), so a NixOS VM test can bring its own CA.
reqwest = { version = "0.12", default-features = false, features = ["rustls-tls-native-roots", "json"] }
# ID token signatures (ES256 from Kanidm, RS256 accepted), PKCE, random tokens
# and the session hashes, as in proplan and the fleet overview.
ring = "0.17"
rustybuzz = "0.20"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
serde_urlencoded = "0.7"
sqlx = { version = "0.8", default-features = false, features = ["runtime-tokio", "postgres", "chrono", "migrate", "macros"] }
tokio = { version = "1", features = ["macros", "net", "rt-multi-thread", "signal", "sync", "time"] }
tracing = "0.1"
tracing-subscriber = { version = "0.3", default-features = false, features = ["fmt"] }
[dev-dependencies]
http-body-util = "0.1"
tower = { version = "0.5", features = ["util"] }
[profile.dev]
# Line tables keep file:line in panics at a fraction of full debug info.
debug = "line-tables-only"
[profile.dev.package."*"]
debug = false
[profile.release]
lto = "thin"
strip = true