Use port 80 for Jenkins

284 views
Skip to first unread message

Martin

unread,
Jul 31, 2015, 2:37:58 PM7/31/15
to Jenkins Users
Hello, I wanted to use "80" for Jenkins server. and I executed the following:

$ java -jar --httpPort=80 jenkins.war

But It doesn't work. The website is not on. My port 80 is available. Then I have to change it back to 8080.

What might cause this? Thank you.

Slide

unread,
Jul 31, 2015, 2:52:34 PM7/31/15
to Jenkins Users
What OS are you running on? On more recent versions of Windows, you have to enable an application to listen on port 80. Linux requires root to run applications that listen on ports under 1000.

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/a3b89f81-11e0-4757-a3d7-b5a5cbd32b13%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Thomas Fürer

unread,
Jul 31, 2015, 3:05:29 PM7/31/15
to jenkins...@googlegroups.com
on many systems you need administrative privileges to use a port between
0 to 1024. normally a apache httpd (or nynx) demon runs at this port and
routes to the internal 8080 port.

tom
> --
> You received this message because you are subscribed to the Google
> Groups "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to jenkinsci-use...@googlegroups.com
> <mailto:jenkinsci-use...@googlegroups.com>.
> <https://groups.google.com/d/msgid/jenkinsci-users/a3b89f81-11e0-4757-a3d7-b5a5cbd32b13%40googlegroups.com?utm_medium=email&utm_source=footer>.

Martin

unread,
Aug 1, 2015, 6:04:40 PM8/1/15
to Jenkins Users
Hey, I was starting the service with a sudo user. So it should be fine in terms of privilege.


On Friday, July 31, 2015 at 3:05:29 PM UTC-4, Thomas Fuerer wrote:
on many systems you need administrative privileges to use a port between
0 to 1024. normally a apache httpd (or nynx) demon runs at this port and
routes to the internal 8080 port.

tom

Am 31.07.2015 um 20:37 schrieb Martin:
> Hello, I wanted to use "80" for Jenkins server. and I executed the
> following:
>
> $ java -jar --httpPort=80jenkins.war
>
>
> But It doesn't work. The website is not on. My port 80 is available.
> Then I have to change it back to 8080.
>
>
> What might cause this? Thank you.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to jenkinsci-use...@googlegroups.com

Mark Waite

unread,
Aug 1, 2015, 6:44:17 PM8/1/15
to jenkins...@googlegroups.com
I would think that running Jenkins as the root user would be a very risky.  If one of the users inadvertently defines a Jenkins job that runs the shell command "rm -rf /", your system will self-destruct.

It is best to find another way, rather than running the Jenkins process as the root user.

Mark Waite

On Sat, Aug 1, 2015 at 4:04 PM Martin <ling...@gmail.com> wrote:
Hey, I was starting the service with a sudo user. So it should be fine in terms of privilege.


On Friday, July 31, 2015 at 3:05:29 PM UTC-4, Thomas Fuerer wrote:
on many systems you need administrative privileges to use a port between
0 to 1024. normally a apache httpd (or nynx) demon runs at this port and
routes to the internal 8080 port.

tom

Am 31.07.2015 um 20:37 schrieb Martin:
> Hello, I wanted to use "80" for Jenkins server. and I executed the
> following:
>
> $ java -jar --httpPort=80jenkins.war
>
>
> But It doesn't work. The website is not on. My port 80 is available.
> Then I have to change it back to 8080.
>
>
> What might cause this? Thank you.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Jenkins Users" group.
> To unsubscribe from this group and stop receiving emails from it, send

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/fe82020c-f033-4e6f-a64d-3ef82b13f035%40googlegroups.com.

Jeff

unread,
Aug 2, 2015, 5:31:52 PM8/2/15
to jenkins...@googlegroups.com
We run jenkins on tomcat on port 8080 but then use iptables to route port 80 to 8080.  Works great.  Here is one sample:




For more options, visit https://groups.google.com/d/optout.



--
Jeff Vincent
See my LinkedIn profile at:
http://www.linkedin.com/in/rjeffreyvincent
Reply all
Reply to author
Forward
0 new messages