Skip to content

fix picture SPI Quarkus Arc crash + reorganise plugins + sops-nix docs#12

Merged
felixevers merged 1 commit into
mainfrom
claude/add-captcha-privacy-signup-x15Hc
May 21, 2026
Merged

fix picture SPI Quarkus Arc crash + reorganise plugins + sops-nix docs#12
felixevers merged 1 commit into
mainfrom
claude/add-captcha-privacy-signup-x15Hc

Conversation

@felixevers
Copy link
Copy Markdown
Member

Bug fix: Keycloak 26 boot fails with
UnsatisfiedResolutionException for PictureConfig / S3Storage
because Quarkus' Arc CDI scanner discovers ProfilePictureResource (has @path) and tries to bean-inject its constructor params, but the params are plain POJOs constructed manually by our factory.

Fix: drop the resource constructor entirely. KeycloakSession is now injected via @context, and the per-instance config + S3Storage live in a new static PictureProviderHolder populated by the factory's init(). All helper classes (resource, holder, config, storage, image processor, multipart parser) are annotated @Vetoed so the scanner skips them.

Folder reorganisation:

  • keycloak-extensions/turnstile-authenticator/ → captcha/
  • keycloak-extensions/privacy-acceptance/ → privacy/
  • keycloak-extensions/profile-picture/ → picture/
    Matching artifactId rename to helpwave-{captcha,privacy,picture} so
    each plugin is short, standalone, and easy to grep.

CI + README + deployment docs updated for the new jar names and paths.

Deployment docs rewritten for sops-nix:

  • secrets/keycloak/r2-{access,secret}-key + turnstile-secret as sops.secrets, owned by keycloak with mode 0400.
  • sops.templates."keycloak.env" rendered to /run/secrets-rendered for the systemd EnvironmentFile (TURNSTILE_SECRET).
  • services.keycloak.settings uses _secret = sops.secrets..path, no /run/keys/ ad-hoc paths.

New .env.example at repo root mirrors every variable from the NixOS config 1:1 so docker compose dev and prod deployments stay aligned.

Version bumped to 0.4.0 to ship the fix.

Bug fix: Keycloak 26 boot fails with
  UnsatisfiedResolutionException for PictureConfig / S3Storage
because Quarkus' Arc CDI scanner discovers ProfilePictureResource (has
@path) and tries to bean-inject its constructor params, but the params
are plain POJOs constructed manually by our factory.

Fix: drop the resource constructor entirely. KeycloakSession is now
injected via @context, and the per-instance config + S3Storage live in
a new static PictureProviderHolder populated by the factory's init().
All helper classes (resource, holder, config, storage, image processor,
multipart parser) are annotated @Vetoed so the scanner skips them.

Folder reorganisation:
- keycloak-extensions/turnstile-authenticator/ → captcha/
- keycloak-extensions/privacy-acceptance/      → privacy/
- keycloak-extensions/profile-picture/         → picture/
Matching artifactId rename to helpwave-{captcha,privacy,picture} so
each plugin is short, standalone, and easy to grep.

CI + README + deployment docs updated for the new jar names and paths.

Deployment docs rewritten for sops-nix:
- secrets/keycloak/r2-{access,secret}-key + turnstile-secret as
  sops.secrets, owned by keycloak with mode 0400.
- sops.templates."keycloak.env" rendered to /run/secrets-rendered for
  the systemd EnvironmentFile (TURNSTILE_SECRET).
- services.keycloak.settings uses _secret = sops.secrets.<name>.path,
  no /run/keys/ ad-hoc paths.

New .env.example at repo root mirrors every variable from the NixOS
config 1:1 so docker compose dev and prod deployments stay aligned.

Version bumped to 0.4.0 to ship the fix.
@felixevers felixevers merged commit ea2bacc into main May 21, 2026
4 checks passed
@felixevers felixevers deleted the claude/add-captcha-privacy-signup-x15Hc branch May 21, 2026 13:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants