35 Commits
Author SHA1 Message Date
wweir 8e5fd3e805 test(install): cover install.sh end to end from make test
install.sh was only syntax-checked (sh -n), so the install and upgrade paths,
the config-preservation contract and the failure modes for a malformed release
tarball had no coverage. Add an offline, unprivileged E2E test that builds its
own tarballs and installs into a temp prefix with --service none: fresh
install, an in-place upgrade that keeps an operator-edited config, --with-server,
a dry run that creates nothing, three malformed tarballs that must fail closed,
and the CLI surface. Wire it into make test as test-install and syntax-check
the new script.
2026-10-10 14:57:10 +08:00
wweir f37e5fa758 feat(install): add a one-shot installer for systemd, procd and launchd
Installing sower meant grabbing a tarball and wiring the service up by hand,
and the packaged unit was too fragile for something a resolver depends on
(on-failure restart after 1min, no memory limit).

Add install.sh: detects the platform and init system, installs or upgrades
the binary atomically, keeps an existing config, verifies the release
SHA256SUMS unless explicitly opted out, and registers the service on systemd,
OpenWrt procd or macOS launchd. Every network call carries an explicit
timeout, the OpenWrt init script ships in Linux tarballs, the release
workflow generates SHA256SUMS, the README documents the installer, and
make test syntax-checks the scripts.
2026-09-18 22:53:55 +08:00
wweir 1dc5f50818 fix(ci): build web assets before running go vet and test
The previous commit stopped tracking web/dist, so the parallel
go vet run no longer finds the embedded dist directory in CI.
Make the test target depend on the web target to guarantee the
frontend is built first.
2026-08-10 16:35:06 +08:00
wweir 1e87298d15 feat(admin): embedded admin console for rule management and traffic stats
- internal/admin: session-cookie auth server, rule CRUD API, bounded
  per-domain traffic stats with pre-parse byte accounting
- cmd/sower: wrap proxied connections and DNS queries into stats, serve the
  admin console on its own listener
- web/: Svelte 5 + Vite admin console with shadcn-svelte UI and an advanced
  breadcrumb header (section/context dropdowns, favorites), embedded via
  go:embed and committed to web/dist
- Makefile: sower build depends on the frontend build (bun); sowerd does not
- docs: ARCHITECTURE, README, and plan updated for the admin surface
2026-08-06 08:56:33 +08:00
wweir af61d38b9e refactor: extract configuration to dedicated config package 2025-10-27 11:28:42 +08:00
wweir dabcf998c9 fix windows release binary 2021-09-09 08:09:59 +08:00
wweir a28a211d2d change ping logix 2021-08-15 13:45:28 +08:00
wweir 397825556c update the document 2021-08-09 06:53:44 +08:00
wweir 5cf8df2a7a change binary name 2021-07-19 16:02:26 +08:00
wweir 8307128844 refactor, start v0.8 2021-07-17 08:05:02 +08:00
wweir c38d519f92 Fix CI 2020-02-17 09:07:01 +08:00
wweir 85226890c5 Support run as system service 2020-02-16 05:57:44 +08:00
wweir 1a24286bbc Refactor to tls 2020-02-15 15:52:15 +08:00
wweir fd5c34dca1 Refactor to proxy router 2020-02-05 18:00:09 +08:00
wweir cbe943a020 Migrate ci from circleci to github actions 2019-09-26 07:52:29 +08:00
wweir bad338033c Fix code 2019-04-16 08:04:37 +08:00
wweir a57f85ab1b Changes for unit test 2019-04-04 10:57:25 +08:00
wweir f001f7dab7 Precompile more platform binary file 2019-03-24 18:44:27 +08:00
wweir 6add7afd19 Fix for go modules 2019-03-15 11:46:51 +08:00
wweir 199e4cf295 For #11, expose suggest level option 2019-03-14 08:38:18 +08:00
wweir 26055c5203 Refactor deploy 2019-03-11 00:11:07 +08:00
wweir 4916245522 Optimize http ping logic 2019-03-06 07:43:45 +08:00
wweir 2adefe0dfc Fix clear dns command for windows 2019-02-26 17:33:39 +08:00
wweir 7ba9f1a23c Fix intelligent detect @release 2019-02-11 20:06:21 +08:00
wweir 9bc5a32074 Add more fuzz match support @release 2019-01-29 13:34:52 +08:00
wweir c20903137d Fix #5, add ipv6 support @release 2019-01-28 16:54:27 +08:00
wweir 712b689708 Force enable go modules 2019-01-25 16:13:22 +08:00
wweir 04193eb608 Change intelligent detect logic @release 2019-01-23 20:10:41 +08:00
wweir 8d0ee2a9ea Add ci scripts 2019-01-19 11:03:32 +08:00
wweir f6eddb9f96 For #1, support for specified a network interface 2019-01-16 14:40:06 +08:00
wweir e712dcb78c Add multi cipher support 2019-01-15 19:00:12 +08:00
wweir d78a757200 Fix shadow conn 2019-01-12 13:53:13 +08:00
wweir 282969b696 Refactor: refactor proxy 2018-12-16 21:25:48 +08:00
wweir 325d1b98b5 refactor with glog 2018-11-24 22:40:40 +08:00
wweir 415c557a8d First init 2018-11-24 21:38:05 +08:00