E: Unable to locate package python-pip

I keep hitting this annoying error, here's a post on how to fix it. No doubt I'll be returning here.

Often, when you start a new (blank) instance on EC2, you have to install stuff like awscli or python-pip. Sometimes it can't find the package and you get this error.

sudo apt-get install python-pip
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package python-pip

This is becuase it is not looking in the right repository. Python-pip is in the universe repository, so you have to add it.

sudo apt-get install software-properties-common
sudo apt-add-repository universe
sudo apt-get update

Then you can install your packages i.e.

sudo apt-get install python-pip
sudo apt-get install awscli