3

Apologies for the noob question. I'm trying to upgrade nginx on my DigitalOcean CentOS7 droplet from 1.8.0 to 1.9.x.

This is my /etc/yum.repos.d/nginx.repo file:

# nginx.repo

[nginx]
name=nginx repo
baseurl=http://nginx.org/packages/centos/7/$basearch/
gpgcheck=0
enabled=1

($basearch is x86_64)

Whenever I run sudo yum install nginx, I get:

Package 1:nginx-1.8.0-1.el7.ngx.x86_64 already installed and latest version

What am I doing wrong?

Donniel Thomas
  • 243
  • 1
  • 3
  • 10

1 Answers1

6

Damn it. I needed to point to the mainline repo, instead of the stable one.

I updated nginx.repo to the following:

# nginx.repo

[nginx]
name=nginx repo
baseurl=http://nginx.org/packages/mainline/centos/$releasever/$basearch/
gpgcheck=0
enabled=1

I now have nginx 1.9.5 :)

Donniel Thomas
  • 243
  • 1
  • 3
  • 10
  • I originally had 1.6.3 installed by following https://www.digitalocean.com/community/tutorials/how-to-install-nginx-on-centos-7 and when I added nginx.repo as you suggested here I only get 1.8.1 -- how can I get the most current version? – isapir Mar 09 '16 at 16:23