Revert "Make use of the new --exists-ok flag for register_new_matrix_user"
This reverts commit 752de4406e
.
Fixes https://github.com/spantaleev/matrix-docker-ansible-deploy/issues/3393
When running the playbook against an existing server, it invokes `register_new_matrix_user`
as part of the `matrix-user-creator` role, which runs before the
`systemd_service_manager`. At that time, `matrix-user-creator` detects
that Synapse is up (from before), but it's the old version. Services have not yet been
restarted, so it's actually the older Synapse version that is up, not
the new one. The old version does not support the `--exists-ok` flag yet.
Basically, this `--exists-ok` patch landed too early and has affected existing playbook
users that have an older version of Synapse in operation.
It will be safer to bring back this patch some time in the future.
However, users upgrading from Synapse <= v1.109.0 even long into the
future will bump into the same issue. As such, it would be better to
either add special handling or to delay bringing back this patch enough
so as to ensure everyone using the playbook is on Synapse >= 1.110.0.
This commit is contained in:
parent
18130f8436
commit
74bb812739
@ -16,7 +16,7 @@
|
|||||||
--user_type={{ user.initial_type | quote }}
|
--user_type={{ user.initial_type | quote }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
--exists-ok
|
|
||||||
http://localhost:{{ matrix_synapse_container_client_api_port }}
|
http://localhost:{{ matrix_synapse_container_client_api_port }}
|
||||||
register: matrix_synapse_register_user_result
|
register: matrix_synapse_register_user_result
|
||||||
changed_when: matrix_synapse_register_user_result.rc == 0 and 'User already exists' not in matrix_synapse_register_user_result.stdout
|
changed_when: matrix_synapse_register_user_result.rc == 0 and 'User ID already taken' not in matrix_synapse_register_user_result.stdout
|
||||||
|
failed_when: matrix_synapse_register_user_result.rc != 0 and 'User ID already taken' not in matrix_synapse_register_user_result.stdout
|
||||||
|
Loading…
Reference in New Issue
Block a user