Skip to content

Commit

Permalink
Remove duplicate entries in sudoers file
Browse files Browse the repository at this point in the history
  • Loading branch information
bensofficial committed Dec 17, 2024
1 parent ff7275e commit fd75e22
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions roles/artemis/templates/artemis_deployment_sudoers.j2
Original file line number Diff line number Diff line change
@@ -1,16 +1,10 @@
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: /bin/systemctl start artemis
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: systemctl start artemis
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: /bin/systemctl stop artemis
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: systemctl stop artemis
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: {{ artemis_working_directory }}/artemis-backup.sh

# Whitelist commands for `artemis-server-cli deploy`
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: /usr/bin/mv /home/{{ artemis_deployment_user_name }}/artemis.war.new {{ artemis_working_directory }}/artemis.war.new
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: mv /home/{{ artemis_deployment_user_name }}/artemis.war.new {{ artemis_working_directory }}/artemis.war.new
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: /usr/bin/rm {{ artemis_working_directory }}/artemis.war.old
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: rm {{ artemis_working_directory }}/artemis.war.old
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: /usr/bin/mv {{ artemis_working_directory }}/artemis.war {{ artemis_working_directory }}/artemis.war.old
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: mv {{ artemis_working_directory }}/artemis.war {{ artemis_working_directory }}/artemis.war.old
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: /usr/bin/mv {{ artemis_working_directory }}/artemis.war.new {{ artemis_working_directory }}/artemis.war
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: mv {{ artemis_working_directory }}/artemis.war.new {{ artemis_working_directory }}/artemis.war
{{ artemis_deployment_user_name }} ALL=(ALL) NOPASSWD: /usr/bin/bash {{ artemis_working_directory }}/artemis-docker.sh restart *

0 comments on commit fd75e22

Please sign in to comment.