Wednesday, April 27, 2016

#495 IaaS - Deploying Docker on Oracle Compute Service



We all know docker - Build, Ship and run anywhere.
So how does this work with Oracle Compute Cloud Service?


Docker containers are essentially lightweight virtualized environments, containing everything you need to run your app.

Step 1 Install docker

Here I install docker on my vm.

Firstly, I update the yum repository.
More info on yum here

Make sure that you are UEK 4.x compatible.

If not, then update -

[ol6_UEKR4]
name=Latest Unbreakable Enterprise Kernel Release 4 for Oracle Linux $releasever ($basearch)
baseurl=http://public-yum.oracle.com/repo/OracleLinux/OL6/UEKR4/$basearch/
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracle
gpgcheck=1
enabled=1

[ol6_UEKR3_latest]
name=Latest Unbreakable Enterprise Kernel for Oracle Linux $releasever ($basearch)
baseurl=http://public-yum.oracle.com/repo/OracleLinux/OL6/UEKR3/latest/$basearch/
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracle
gpgcheck=1
enabled=0

[ol6_UEK_latest]
name=Latest Unbreakable Enterprise Kernel for Oracle Linux $releasever ($basearch)
baseurl=http://public-yum.oracle.com/repo/OracleLinux/OL6/UEK/latest/$basearch/
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracle
gpgcheck=1
enabled=0


copy the above to your /etc/yu.repos.d/public-yum-ol6.repo file

then run sudo yum update

Once this is complete, then install docker -

sudo yum install docker-engine









Step 2 -Start docker

sudo service docker start






do the sanity test -
sudo docker run hello-world


















Now, let's run an Ubuntu container -

docker run -it ubuntu bash
















docker containers are stored here -






Good article on getting started with docker available here


No comments: