Skip to content

Commit

Permalink
Consolidate permissions fix, remove chown-rootadmin if exists
Browse files Browse the repository at this point in the history
  • Loading branch information
jwokaty committed Oct 17, 2023
1 parent b98fda0 commit 181b36f
Showing 1 changed file with 4 additions and 11 deletions.
15 changes: 4 additions & 11 deletions saltstack/salt/common/mac.sls
Original file line number Diff line number Diff line change
Expand Up @@ -215,11 +215,6 @@ symlink_gfortran_sdk:
- require:
- file: export_gfortran_path

fix_/usr/local_permissions_for_brewing:
cmd.run:
- name: |
chown -R {{ machine.user.name }}:admin /usr/local/*
brew_packages:
cmd.run:
- name: brew install {{ machine.brews }}
Expand All @@ -242,12 +237,6 @@ append_openssl_configurations_to_path:
- require:
- cmd: install_openssl

fix_/usr/local_permissions_for_binaries:
cmd.run:
- name: |
chown -R {{ machine.user.name }}:admin /usr/local/*
chown -R root:wheel /usr/local/texlive
install_pip_pkgs:
cmd.run:
- name: python3 -m pip install $(cat {{ machine.user.home }}/{{ machine.user.name }}/{{ repo.bbs.name }}/Ubuntu-files/22.04/pip_*.txt | awk '/^[^#]/ {print $1}')
Expand Down Expand Up @@ -297,6 +286,10 @@ fix_/usr/local_permissions:
- cmd: install_mactex
- cmd: install_pandoc

remove_chown-rootadmin:
file.absent:
- name: {{ machine.user.home }}/{{ machine.user.name }}/BBS/utils/chown-rootadmin

run_chown-rootadmin:
cmd.run:
- name: gcc chown-rootadmin.c -o chown-rootadmin
Expand Down

0 comments on commit 181b36f

Please sign in to comment.