mirror of
https://github.com/shivammathur/setup-php.git
synced 2024-11-23 04:11:06 +07:00
Merge pull request #249 from lolautruche/fix-blackfire
Remove sudo for Blackfire config when it's not needed
This commit is contained in:
commit
9845a63f5c
@ -200,11 +200,11 @@ add_blackfire() {
|
|||||||
brew tap --shallow blackfireio/homebrew-blackfire >/dev/null 2>&1
|
brew tap --shallow blackfireio/homebrew-blackfire >/dev/null 2>&1
|
||||||
brew install blackfire-agent >/dev/null 2>&1
|
brew install blackfire-agent >/dev/null 2>&1
|
||||||
if [[ -n $BLACKFIRE_SERVER_ID ]] && [[ -n $BLACKFIRE_SERVER_TOKEN ]]; then
|
if [[ -n $BLACKFIRE_SERVER_ID ]] && [[ -n $BLACKFIRE_SERVER_TOKEN ]]; then
|
||||||
sudo blackfire-agent --register --server-id="$BLACKFIRE_SERVER_ID" --server-token="$BLACKFIRE_SERVER_TOKEN" >/dev/null 2>&1
|
blackfire-agent --register --server-id="$BLACKFIRE_SERVER_ID" --server-token="$BLACKFIRE_SERVER_TOKEN" >/dev/null 2>&1
|
||||||
brew services start blackfire-agent >/dev/null 2>&1
|
brew services start blackfire-agent >/dev/null 2>&1
|
||||||
fi
|
fi
|
||||||
if [[ -n $BLACKFIRE_CLIENT_ID ]] && [[ -n $BLACKFIRE_CLIENT_TOKEN ]]; then
|
if [[ -n $BLACKFIRE_CLIENT_ID ]] && [[ -n $BLACKFIRE_CLIENT_TOKEN ]]; then
|
||||||
sudo blackfire config --client-id="$BLACKFIRE_CLIENT_ID" --client-token="$BLACKFIRE_CLIENT_TOKEN" >/dev/null 2>&1
|
blackfire config --client-id="$BLACKFIRE_CLIENT_ID" --client-token="$BLACKFIRE_CLIENT_TOKEN" >/dev/null 2>&1
|
||||||
fi
|
fi
|
||||||
add_log "$tick" "blackfire" "Added"
|
add_log "$tick" "blackfire" "Added"
|
||||||
add_log "$tick" "blackfire-agent" "Added"
|
add_log "$tick" "blackfire-agent" "Added"
|
||||||
|
@ -327,7 +327,7 @@ add_blackfire() {
|
|||||||
sudo /etc/init.d/blackfire-agent restart >/dev/null 2>&1
|
sudo /etc/init.d/blackfire-agent restart >/dev/null 2>&1
|
||||||
fi
|
fi
|
||||||
if [[ -n $BLACKFIRE_CLIENT_ID ]] && [[ -n $BLACKFIRE_CLIENT_TOKEN ]]; then
|
if [[ -n $BLACKFIRE_CLIENT_ID ]] && [[ -n $BLACKFIRE_CLIENT_TOKEN ]]; then
|
||||||
sudo blackfire config --client-id="$BLACKFIRE_CLIENT_ID" --client-token="$BLACKFIRE_CLIENT_TOKEN" >/dev/null 2>&1
|
blackfire config --client-id="$BLACKFIRE_CLIENT_ID" --client-token="$BLACKFIRE_CLIENT_TOKEN" >/dev/null 2>&1
|
||||||
fi
|
fi
|
||||||
add_log "$tick" "blackfire" "Added"
|
add_log "$tick" "blackfire" "Added"
|
||||||
add_log "$tick" "blackfire-agent" "Added"
|
add_log "$tick" "blackfire-agent" "Added"
|
||||||
|
Loading…
Reference in New Issue
Block a user