Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Uninstallation of matrix_synapse_reverse_proxy_companion_service fails #2444

Closed
Michael-Hollister opened this issue Feb 6, 2023 · 0 comments

Comments

@Michael-Hollister
Copy link
Contributor

Describe the bug
The matrix-synapse-reverse-proxy-companion role fails its uninstallation task if you have previously installed Synapse on your server, and decide to change to Conduit or Dendrite

A workaround i'm currently using is to delete matrix-synapse-reverse-proxy-companion.service manually in /etc/systemd/system/ before I run just setup-all for setting up Conduit/Dendrite, but my understanding is that the matrix-synapse-reverse-proxy-companion uninstallation task should take care of removing itself from the service directory.

To Reproduce

Starting from the default vars.yml example file with updates to default entries + adding ansible_ssh_private_key_file. Ensure that matrix_homeserver_implementation is Synapse and that workers are enabled so that the matrix-synapse-reverse-proxy-companion service is created.

  1. If not ran yet: just roles
  2. just setup-all
  3. just start-all
  4. just stop-all
  5. Change in vars.yml the field matrix_homeserver_implementation to conduit or dendrite
  6. just setup-all

The error output after running the last command:

TASK [custom/matrix-synapse-reverse-proxy-companion : Ensure matrix-synapse-reverse-proxy-companion.service is stopped] *****
task path: /matrix_test2/roles/custom/matrix-synapse-reverse-proxy-companion/tasks/setup_uninstall.yml:10

...

fatal: [<SERVER>]: FAILED! => changed=false 
  invocation:
    module_args:
      daemon_reexec: false
      daemon_reload: true
      enabled: false
      force: null
      masked: null
      name: matrix_synapse_reverse_proxy_companion_service_stat
      no_block: false
      scope: system
      state: stopped
  msg: 'Could not find the requested service matrix_synapse_reverse_proxy_companion_service_stat: host'

Error Cause
If the service matrix-synapse-reverse-proxy-companion.service still exists in /etc/systemd/system/, then this error will happen. As mentioned earlier, if you remove this file manually before running just setup-all, then this task will pass.

Matrix Server:

  • OS: Rocky Linux RockyLinux 8.6 x64
  • Architecture: amd64

Ansible:

  • where you run Ansible: On the Matrix server, standard installation
  • what version of Ansible you're running:
ansible [core 2.13.3]
  config file = /matrix_test2/ansible.cfg
  configured module search path = ['/root/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/lib/python3.9/site-packages/ansible
  ansible collection location = /root/.ansible/collections:/usr/share/ansible/collections
  executable location = /usr/bin/ansible
  python version = 3.9.13 (main, Nov  8 2022, 17:21:43) [GCC 8.5.0 20210514 (Red Hat 8.5.0-15)]
  jinja version = 3.1.2
  libyaml = True
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant