revert name and namespace , and switch to update and create
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 3s
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 3s
This commit is contained in:
@@ -9,6 +9,5 @@ def import_namespace(queryset):
|
||||
def import_deployment(queryset):
|
||||
deployment_list = get_deployments()
|
||||
for deployment in deployment_list:
|
||||
#not tested yet , we might be able to parse every lines like that
|
||||
queryset.objects.create(name=deployment[0],namespace=deployment[1],replicas=deployment[2])
|
||||
queryset.objects.update_or_create(namespace=deployment[0],name=deployment[1],defaults={"replicas":deployment[2]})
|
||||
|
||||
Reference in New Issue
Block a user