airflow-gcp-k8s
airflow-gcp-k8s copied to clipboard
Syntax error
In the first command, unfortunately
python2 gcp-airflow.py
File "gcp-airflow.py", line 116
,)
^
SyntaxError: invalid syntax
Deleting the two commas does at least let the script execute, no idea if its ok though https://github.com/iihnordic/airflow-gcp-k8s/blob/master/gcp-airflow.py
I guess if like other functions it needs apply_changes
def deploy_airflow(name, image_suffix):
def apply_changes(service):
service['metadata']['labels']['version'] = version
service['spec']['template']['metadata']['labels']['version'] = version
service['spec']['template']['spec']['containers'][0][
'image'] = repo + '/airflow-' + image_suffix + ':' + version
execute_with_yaml('k8s/airflow-' + name + '-deploy.yaml',
['kubectl', 'create', '--namespace', namespace, '-f', '-'],
apply_changes)