mirror of
https://github.com/truenas/charts.git
synced 2026-11-04 00:24:19 +00:00
Add upgrade strategy for emby
This commit is contained in:
1 parent
364bd5d5c6
commit
12aa5064ca
2 files changed
+25
No files matched your search
@@ -0,0 +1 @@
|
||||
{"filename": "ix_values.yaml", "keys": ["image"], "test_filename": "test_values.yaml"}
|
||||
Executable
+24
@@ -0,0 +1,24 @@
|
||||
#!/usr/bin/python3
|
||||
import json
|
||||
import sys
|
||||
|
||||
from catalog_update.upgrade_strategy import semantic_versioning
|
||||
|
||||
|
||||
def newer_mapping(image_tags):
|
||||
key = list(image_tags.keys())[0]
|
||||
version = semantic_versioning(sorted(image_tags[key], reverse=True))
|
||||
if not version:
|
||||
return {}
|
||||
|
||||
return {
|
||||
'tags': {key: version},
|
||||
'app_version': version,
|
||||
}
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
if len(sys.argv) != 2:
|
||||
exit(1)
|
||||
|
||||
print(json.dumps(newer_mapping(json.loads(sys.argv[1]))))
|
||||
Reference in new issue
Block a user