This is probably very simple, but I can't find any hint anywhere. So how one is supposed to do that, in general and specifically on Mac?
-
1To dodge this entirely, use docker! https://hub.docker.com/r/jenkins/jenkins/ – Ben Creasy Feb 06 '18 at 16:13
8 Answers
These instructions apply if you installed using the official Jenkins Mac installer from http://jenkins-ci.org/
Execute uninstall script from terminal:
'/Library/Application Support/Jenkins/Uninstall.command'
or use Finder to navigate into that folder and double-click on Uninstall.command.
Finally delete last configuration bits which might have been forgotten:
sudo rm -rf /var/root/.jenkins ~/.jenkins
If the uninstallation script cannot be found (older Jenkins version), use following commands:
sudo launchctl unload /Library/LaunchDaemons/org.jenkins-ci.plist
sudo rm /Library/LaunchDaemons/org.jenkins-ci.plist
sudo rm -rf /Applications/Jenkins "/Library/Application Support/Jenkins" /Library/Documentation/Jenkins
and if you want to get rid of all the jobs and builds:
sudo rm -rf /Users/Shared/Jenkins
and to delete the jenkins user and group (if you chose to use them):
sudo dscl . -delete /Users/jenkins
sudo dscl . -delete /Groups/jenkins
These commands are also invoked by the uninstall script in newer Jenkins versions, and should be executed too:
sudo rm -f /etc/newsyslog.d/jenkins.conf
pkgutil --pkgs | grep 'org\.jenkins-ci\.' | xargs -n 1 sudo pkgutil --forget
-
I think it can be included into installer as an option, in customize section. Or I believe there should be some delete hooks, when user decides to drop application into trash bin. But what's that "sudo rm !$" for? – jayarjo Jul 24 '12 at 06:52
-
-
1I have never seen Mac applications uninstalled using a customized installation or by setting up a folder action for Trash. Can you point me to some examples of those? – sti Jul 24 '12 at 20:31
-
41The above commands will be found in `/Library/Application Support/Jenkins/Uninstall.command` hopefully in a couple of weeks. – sti Jul 24 '12 at 22:44
-
Thank you so much for this! The fact that Jenkins comes with no way to uninstall on Mac is a complete travesty. – Zarkonnen Jan 05 '13 at 20:08
-
1Since it looks like the Uninstall.command script is there now, it'd be good to update the first part of the answer with that (though having the info for folks with older installations is still very handy). – Alex Dixon Jan 21 '13 at 16:25
-
For anyone who is directly pasting the command to run the uninstall script, use the below command. `/Library/Application\ Support/Jenkins/Uninstall.command` – being_j Mar 08 '19 at 14:46
You are right, it is simple. Run (admin password required):
'/Library/Application Support/Jenkins/Uninstall.command'
It may be necessary to do this with admin privileges using sudo.

- 5,948
- 8
- 42
- 72

- 1,216
- 10
- 12
-
This helped a ton. I'm shocked that this information isn't more prevalent anywhere in Mac's documentation. – Makoto Feb 28 '13 at 04:23
-
3I thought StackOverflow is the ipso facto default documentation for **everything** :) I've found more (case specific and most of the times better explained) answers here than most application documents :) – javatarz Jun 25 '13 at 08:10
-
1Thanks! Would be awesome if the OP could change the accepted answer for this one. – xmarcos Sep 04 '13 at 02:48
Keep in mind, that in Terminal you need to add backslash before space, so the proper copy/paste will be
/Library/Application\ Support/Jenkins/Uninstall.command
p.s. sorry for the late answer :)

- 480
- 3
- 12
-
I think this should be a comment (to which answer?). Thw two highest answers have quotes around the command to protect the space from interpretation of the shell. – Brandin Jul 16 '15 at 12:15
run this on Terminal:
sh "/Library/Application Support/Jenkins/Uninstall.command"

- 13,481
- 5
- 68
- 74
-
4As of May 2017 there isn't even a Jenkins folder in Application Support – brainray May 29 '17 at 07:19
There is no uninstaller. Therefore, you need to:
Delete the directory containing Jenkins (or, if you're deploying the war -- remove the war from your container).
Remove ~/.jenkins.
Remove you startup scripts.

- 31,231
- 29
- 115
- 197
-
Well, I was referring to scripts like the rc init scripts. If you haven't set up any, then just removing jenkins is enough. – carlspring Jul 23 '12 at 11:34
-
I've installed it through Mac OS X installer, so not sure what did it create :| – jayarjo Jul 23 '12 at 11:53
-
I recommend, you just delete the folders then. Let me know, if have any problems. – carlspring Jul 23 '12 at 12:47
My Jenkins version: 1.5.39
Execute steps:
Step 1. Go to folder /Library/Application Support/Jenkins
Step 2. Run Uninstall.command jenkins-runner.sh
file.
Step 3. Check result.
It work for me.
-
1There is no Jenkins version '1.5.39'. And this is only a incomplete copy of previous answers. – t0r0X Mar 22 '15 at 14:31
Run the following commands to completely uninstall Jenkins from MacOS Sierra. You don't need to change anything, just run these commands.
sudo launchctl unload /Library/LaunchDaemons/org.jenkins-ci.plist
sudo rm /Library/LaunchDaemons/org.jenkins-ci.plist
sudo rm -rf /Applications/Jenkins '/Library/Application Support/Jenkins' /Library/Documentation/Jenkins
sudo rm -rf /Users/Shared/Jenkins
sudo rm -rf /var/log/jenkins
sudo rm -f /etc/newsyslog.d/jenkins.conf
sudo dscl . -delete /Users/jenkins
sudo dscl . -delete /Groups/jenkins
pkgutil --pkgs
grep 'org\.jenkins-ci\.'
xargs -n 1 sudo pkgutil --forget
Salam
Shah

- 648
- 8
- 10

- 1,129
- 12
- 10
On Mac; these two below commands completely remove Jenkins from your machine. just open your Terminal and execute them:
- '/Library/Application Support/Jenkins/Uninstall.command' and
- sudo rm -rf /var/root/.jenkins ~/.jenkins
Thanks

- 151
- 1
- 7