Skip to content

Commit

Permalink
Modify startup scripts to run as user not root
Browse files Browse the repository at this point in the history
  • Loading branch information
peterMuriuki committed Feb 5, 2020
1 parent 9c370e6 commit 447c8e8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tasks/configure.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,15 +61,15 @@

- name: delete the old startup file
become: true
become_user: "root"
become_user: "{{ express_system_user }}"
command: "{{ express_pm2_path }} unstartup -u {{ express_system_user }} --service-name {{ express_service_name }} --hp {{ express_system_user_home }}"
ignore_errors: yes
notify:
- start_express_service

- name: Generate an express PM2 init service file
become: true
become_user: "root"
become_user: "{{ express_system_user }}"
command: "{{ express_pm2_path }} startup -u {{ express_system_user }} --hp {{ express_system_user_home }} --service-name {{ express_service_name }}"
notify:
- start_express_service

0 comments on commit 447c8e8

Please sign in to comment.