Remove the sync.Mutex and CreateUserAtomic (INSERT ON CONFLICT) in favor of a single DB transaction in CreateFirstUser that atomically checks for existing users and inserts. SQLite serializes write transactions, so this is sufficient to prevent the race condition without application-level locking. |
||
|---|---|---|
| .. | ||
| app.go | ||
| deployment.go | ||
| env_var.go | ||
| label.go | ||
| models_test.go | ||
| port.go | ||
| user.go | ||
| volume.go | ||
| webhook_event.go | ||