Skip to content

Commit

Permalink
.bashrc fixed alias for puppet
Browse files Browse the repository at this point in the history
  • Loading branch information
fb929 committed Sep 15, 2023
1 parent 8d43b84 commit 4371025
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions .bashrc
Original file line number Diff line number Diff line change
Expand Up @@ -254,15 +254,13 @@ export SCREENDIR=$HOME/.screen

# puppet
alias pagent='puppet agent -t'
alias pagent_noop='puppet agent -t --noop'
alias pagentNoop='puppet agent -t --noop'
alias pagentMyenv='puppet agent -t --environment=gefimov'
alias pagentMyenv_noop='puppet agent -t --environment=gefimov --noop'
alias pagentMyenvLocal='puppet agent -t --environment=gefimov_local'
alias pagentMyenvLocal_noop='puppet agent -t --environment=gefimov_local --noop'
alias pagentMyenvNoop='puppet agent -t --environment=gefimov --noop'
if [[ -s /etc/puppet/puppet.conf ]]; then
if grep -qw environment /etc/puppet/puppet.conf; then
PUPPET_ENV=$( grep -w environment /etc/puppet/puppet.conf | head -1 | awk '{print $NF}' )
alias pagentPenv_noop="puppet agent -t --noop --environment=gefimov_$PUPPET_ENV"
alias pagentPenvNoop="puppet agent -t --environment=gefimov_$PUPPET_ENV --noop"
alias pagentPenv="puppet agent -t --environment=gefimov_$PUPPET_ENV"
fi
fi
Expand Down

0 comments on commit 4371025

Please sign in to comment.