Closes #90 ChangeLogs: * https://github.com/goauthentik/authentik/releases/tag/version%2F2025.12.2 * https://github.com/goauthentik/authentik/releases/tag/version%2F2025.12.3 Using the `client-go` library that is vendored in this release's `go.mod` breaks all outposts for me, so we're now doing what upstream is also doing, i.e. generating the Go client code ourselves.
20 lines
502 B
Nix
20 lines
502 B
Nix
{
|
|
authentik-src,
|
|
authentik-go,
|
|
openapi-generator-cli,
|
|
runCommand,
|
|
}:
|
|
|
|
runCommand "go-client-code" {
|
|
nativeBuildInputs = [
|
|
openapi-generator-cli
|
|
];
|
|
} ''
|
|
cp --no-preserve=mode -vr ${authentik-go}/ $out/
|
|
cp -vr ${authentik-src}/schema.yml $out/
|
|
pushd $out &>/dev/null
|
|
substituteInPlace config.yaml \
|
|
--replace-fail "templateDir: /local/templates/" "templateDir: ./templates/"
|
|
openapi-generator-cli generate -i schema.yml -g go -o . -c config.yaml
|
|
popd &>/dev/null
|
|
''
|