fix: restart opencode acp through launchd

This commit is contained in:
Haitao Pan 2026-06-18 14:51:40 +08:00
parent 5e3db5dfd5
commit c7784f2063

View File

@ -3,8 +3,21 @@
ansible.builtin.service: ansible.builtin.service:
name: caddy name: caddy
state: reloaded state: reloaded
when: ansible_os_family != 'Darwin'
- name: Restart acp opencode - name: Restart acp opencode
ansible.builtin.service: ansible.builtin.service:
name: "{{ acp_opencode_service_name }}" name: "{{ acp_opencode_service_name }}"
state: restarted state: restarted
when: ansible_os_family != 'Darwin'
- name: Restart acp opencode on macOS
ansible.builtin.command: "launchctl stop plus.svc.xworkspace.acp.opencode"
register: launchctl_stop
failed_when: false
changed_when: false
notify: Start acp opencode on macOS
- name: Start acp opencode on macOS
ansible.builtin.command: "launchctl start plus.svc.xworkspace.acp.opencode"
changed_when: false