Installed Nginx with passenger-install-nginx-module. How do I uninstall it?
I'm on Mac OSX. Nginx is install开发者_开发知识库ed in /opt/nginx.
How do I uninstall it? Any thoughts?
gem uninstall passenger
will remove passenger and all these dependencies
passenger, passenger-install-apache2-module, passenger-install-nginx-module, passenger-config, passenger-status, passenger-memory-stats, passenger-make-enterprisey
Passenger's documentation covers this:
To uninstall Phusion Passenger, please first remove all Phusion Passenger configuration directives from your web server configuration file(s). After you’ve done this, you need to remove the Phusion Passenger files.
- If you installed Phusion Passenger through Homebrew, then run
brew uninstall passenger
.- If you installed Phusion Passenger via a Ruby gem, then run
gem uninstall passenger
(or, if you’re a Phusion Passenger Enterprise user,gem uninstall passenger-enterprise-server
). You might have to run this as root.- If you installed Phusion Passenger via a source tarball, then remove the directory in which you placed the extracted Phusion Passenger files. This directory is the same as the one pointed to the by
PassengerRoot/passenger_root
configuration directive.- If you installed Phusion Passenger through APT or YUM, then use them to uninstall Phusion Passenger.
Nginx does not have to be recompiled after uninstalling Phusion Passenger. Altough Nginx will contain the Phusion Passenger Nginx module, the module will not do anything when all Phusion Passenger configuration directives are removed.
At that point you can remove nginx by running
sudo rm -rf /opt/nginx
if you installed it using source.
Use your package manager to remove it if you installed it that way.
Run following command from your terminal:
For Debian/Ubuntu
sudo apt-get remove -y passenger
Red Hat/CentOS
sudo yum remove -y passenger
macOS + Homebrew
brew uninstall passenger
Ruby gem
gem uninstall passenger
精彩评论