Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Run old Linux release in a Docker container?

Tags:

docker

I've got a binary application that won't work on versions of Ubuntu later than Feisty.

Is it possible to build a Docker image containing Feisty and run it on my modern system?

like image 630
GaryBishop Avatar asked Dec 06 '13 01:12

GaryBishop


2 Answers

I'll add more detail than I am allowed in the comments. These are the steps I used to get a 32-bit release of Ubuntu Feisty working in a Docker 0.7.1 container.

cd /tmp
sudo debootstrap --arch=i386 feisty feisty http://old-releases.ubuntu.com/ubuntu
sudo tar -C feisty -c . | docker import - feisty

Now I have a 32-bit feisty base image. I banged out a Dockerfile and my ancient code appears to work correctly in the container.

like image 175
GaryBishop Avatar answered Sep 29 '22 12:09

GaryBishop


You should be able to build your own base image. I'm not aware of any reasons why it should not work.

Check out the documentation http://docs.docker.io/en/latest/use/baseimages/ for a starting point and keep us posted :)

like image 42
qkrijger Avatar answered Sep 29 '22 12:09

qkrijger