mirror of
https://github.com/goauthentik/authentik.git
synced 2026-06-17 19:09:11 +03:00
root: fix compose generation for patch releases release candidates (#21353)
* root: fix compose generation for patch releases release candidates Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space> * add comment Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space> --------- Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space>
This commit is contained in:
committed by
GitHub
parent
84581a0dbd
commit
111f0c072f
@@ -1,12 +1,21 @@
|
|||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
|
|
||||||
|
from packaging.version import parse
|
||||||
from yaml import safe_dump
|
from yaml import safe_dump
|
||||||
|
|
||||||
from authentik import authentik_version
|
from authentik import authentik_version
|
||||||
|
|
||||||
authentik_image = (
|
version = authentik_version()
|
||||||
f"${{AUTHENTIK_IMAGE:-ghcr.io/goauthentik/server}}:${{AUTHENTIK_TAG:-{authentik_version()}}}"
|
version_parsed = parse(version)
|
||||||
)
|
version_split = version_parsed.base_version.split(".")
|
||||||
|
# If this is an rc version for a patch release (i.e. 2026.2.2-rc1), then don't include that in the
|
||||||
|
# compose, and fallback to the previous released patch version
|
||||||
|
if version_parsed.is_prerelease and version_split[-1] != "0":
|
||||||
|
previous_patch = int(version_split[-1]) - 1
|
||||||
|
version_split[-1] = str(previous_patch)
|
||||||
|
version = ".".join(version_split)
|
||||||
|
|
||||||
|
authentik_image = f"${{AUTHENTIK_IMAGE:-ghcr.io/goauthentik/server}}:${{AUTHENTIK_TAG:-{version}}}"
|
||||||
|
|
||||||
base = {
|
base = {
|
||||||
"services": {
|
"services": {
|
||||||
|
|||||||
Reference in New Issue
Block a user