···2424go run ./cmd/wizard
2525```
26262727-Your choices are saved so next time you just press Enter to relaunch with the same settings.
2727+Your choices are saved so next time you just press Enter to relaunch with the same settings. To skip the confirmation prompt entirely (useful for scripts or quick relaunches), pass `--prefer-saved`:
2828+2929+```bash
3030+go run ./cmd/wizard --prefer-saved
3131+```
3232+3333+If no saved config exists, the flag prints an error and exits.
28342935#### Custom Ports
3036···3440go run ./cmd/wizard --grpc-port 9003 --cdn-port 9080
3541```
36423737-| Flag | Default | Description |
3838-| ------------- | ------- | ---------------- |
3939-| `--grpc-port` | `8003` | gRPC server port |
4040-| `--cdn-port` | `8080` | CDN server port |
4141-| `--auth-port` | `3000` | Auth server port |
4343+| Flag | Default | Description |
4444+| ---------------- | ------- | ---------------------------------- |
4545+| `--prefer-saved` | `false` | Reuse saved config without prompting |
4646+| `--grpc-port` | `8003` | gRPC server port |
4747+| `--cdn-port` | `8080` | CDN server port |
4848+| `--auth-port` | `3000` | Auth server port |
42494350Custom ports are saved to `.wizard.json` alongside your other settings. On the next run the saved ports are reused automatically — no need to pass the flags again. If you later pass different port flags, the wizard warns you that the ports changed and asks for confirmation before continuing.
4451
+17-3
server/cmd/wizard/main.go
···55555656func main() {
5757 setupOnly := flag.Bool("setup-only", false, "show patching instructions and exit without building or launching")
5858+ preferSaved := flag.Bool("prefer-saved", false, "reuse saved config without prompting")
5859 grpcPort := flag.Int("grpc-port", defaultGRPCPort, "gRPC server port")
5960 cdnPort := flag.Int("cdn-port", defaultCDNPort, "CDN server port")
6061 authPort := flag.Int("auth-port", defaultAuthPort, "auth server port")
···7778 downloadDeps()
7879 }
79808080- ip, cfg, firstRun := resolveIP()
8181+ ip, cfg, firstRun := resolveIP(*preferSaved)
81828283 p := resolvePorts(flagSet, *grpcPort, *cdnPort, *authPort, cfg)
8384 savedPorts := portsFromConfig(cfg)
···311312 }
312313}
313314314314-func resolveIP() (string, config, bool) {
315315- if cfg, err := loadConfig(); err == nil {
315315+func resolveIP(preferSaved bool) (string, config, bool) {
316316+ cfg, err := loadConfig()
317317+ if err == nil {
318318+ if preferSaved {
319319+ if isLANBased(cfg) {
320320+ if ip, updated, ok := recheckLANIP(cfg); ok {
321321+ return ip, updated, false
322322+ }
323323+ }
324324+ return cfg.IP, cfg, false
325325+ }
326326+316327 ip, cfg, done := handleSavedConfig(cfg)
317328 if done {
318329 return ip, cfg, false
319330 }
331331+ } else if preferSaved {
332332+ fmt.Fprintln(os.Stderr, " --prefer-saved: no saved config found; run without the flag first.")
333333+ os.Exit(1)
320334 }
321335322336 ip, cfg := runWizard()