0

I'm working on updating Nginx on my server from 0.7.65 (Ubuntu 10.04 repo) to 1.0.2 (from the PPA). I installed it just fine, but I would like to add/activate some modules. I found this tutorial for doing it with dpkg, which works well for ensuring that it maintains the defaults that apt-get uses for things like install location, and would like to use it to do the same for 1.0.2.

However, when I run apt-get source nginx, it downloads the 0.7 source from the main repo, and when I run apt-get source nginx-full or apt-get source nginx-common, it selects nginx instead.

Is there any way I can force it to get the source from the PPA, so that I can use dpkg and not have to deal with hacking in the Debian folder that dpkg requires?

Shauna
  • 178
  • 1
  • 7

3 Answers3

1

You can specify version to apt.

For example: apt-get source nginx=1.0.2

mboehn
  • 377
  • 1
  • 9
  • Sorry it's taken me so long to respond. That worked to attempt to get the package (and it actually found it), but it didn't download it. It came up with `Ignore unavailable version '1.0.2-0ppa1~lucid' of package 'nginx'. Unable to find a source package for nginx`. 'apt-cache policy nginx` returns 1.0.2-0ppa1~lucid for the first listing of available sources and the Candidate. – Shauna May 31 '11 at 11:44
  • Try with a wildcard: `apt-get source nginx=1.0.2*` maybe. – raphink Apr 02 '12 at 11:16
0

To expand on @mboehn's answer: you can see the available versions of a package (and which repositories they come from) with apt-cache policy package.

Eduardo Ivanec
  • 14,881
  • 1
  • 37
  • 43
0

Add the following to /etc/apt/sources.list.d/nginx-stable-lucid.list

deb-src http://ppa.launchpad.net/nginx/stable/ubuntu lucid main
windyjonas
  • 143
  • 1
  • 1
  • 7