Skip to content

Commit

Permalink
Disable reverse sync for data create and createsuperuser
Browse files Browse the repository at this point in the history
  • Loading branch information
AlanCoding authored and rooftopcellist committed Oct 9, 2024
1 parent 20f3812 commit 8fdc82e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion roles/eda/tasks/create_admin_user.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
namespace: "{{ ansible_operator_meta.namespace }}"
pod: "{{ eda_api_pod_name }}"
container: "eda-api"
command: bash -c "DJANGO_SUPERUSER_PASSWORD={{ admin_password }} aap-eda-manage createsuperuser --username={{ admin_user | quote }} --email={{ admin_email | quote }} --noinput"
command: bash -c "DJANGO_SUPERUSER_PASSWORD={{ admin_password }} ANSIBLE_REVERSE_RESOURCE_SYNC=false aap-eda-manage createsuperuser --username={{ admin_user | quote }} --email={{ admin_email | quote }} --noinput"
register: result
changed_when: "'That username is already taken' not in result.stderr"
failed_when: "'That username is already taken' not in result.stderr and 'Superuser created successfully' not in result.stdout"
Expand Down
2 changes: 2 additions & 0 deletions roles/eda/templates/eda-api.deployment.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,8 @@ spec:
- configMapRef:
name: '{{ ansible_operator_meta.name }}-{{ deployment_type }}-env-properties'
env:
- name: ANSIBLE_REVERSE_RESOURCE_SYNC
value: 'true'
- name: EDA_DB_HOST
valueFrom:
secretKeyRef:
Expand Down

0 comments on commit 8fdc82e

Please sign in to comment.