Bobs-MacBook-Pro-2:~ bobhannan$ brew services start mongodb
Error: Unknown command: services
Bobs-MacBook-Pro-2:~ bobhannan$ brew services list
Error: Unknown command: services
서비스 대신 서비스를 사용하는 데에도 문제가 있습니다.
답변1
라는 명령이 없습니다 brew services
.
다음이 존재합니다:
brew install
brew uninstall
brew search
brew list
brew update
brew upgrade
brew pin/unpin
brew doctor
brew install -vd
brew --env | config
brew create URL --no-fetch
brew edit
다음을 사용하여 설치할 수 있습니다.
curl -o /usr/local/bin/brew-services.rb https://gist.githubusercontent.com/lwe/766293/raw/75a7907004bbff0eb3b072d1d951be2cfe7e5020/brew-services.rb
chmod +x /usr/local/bin/brew-services.rb
brew services help
답변2
먼저 homebrew/boneyard를 한 번 클릭하여 Brew 서비스를 설치합니다.
brew tap homebrew/boneyard
참고: mongo를 자동으로 시작하도록 launchctl을 설정하십시오.
$ launchctl 로드 ~/Library/LaunchAgents/homebrew.mxcl.mongo.plist $ launchctl 언로드 ~/Library/LaunchAgents/homebrew.mxcl.mongo.plist
원천:http://robots.thoughtbot.com/starting-and-stopping-Background-services-with-homebrew