FROM centos:centos6 MAINTAINER Robert Cowham "rcowham@perforce.com" RUN yum update -y; \ # Tools required to compile and build Python \ yum install -y sudo; \ yum install -y wget; \ yum groupinstall -y "Development tools"; \ yum install -y zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel readline-devel tk-devel gdbm-devel db4-devel libpcap-devel xz-devel; \ echo /usr/local/lib>> /etc/ld.so.conf; \ sed -ie "s/^Defaults[ \t]*requiretty/#Defaults requiretty/g" /etc/sudoers # Python 3.4 RUN cd /tmp; \ PYVER=3.4.2; \ wget -q http://www.python.org/ftp/python/${PYVER}/Python-${PYVER}.tar.xz; \ tar xJf ./Python-${PYVER}.tar.xz; \ cd ./Python-${PYVER}; \ ./configure --prefix=/usr/local --enable-shared LDFLAGS="-Wl,-rpath /usr/local/lib"; \ make; \ make altinstall; \ cd /tmp; \ rm -rf ./Python-${PYVER}.xz ./Python-${PYVER} # Build P4Python RUN pip3.4 install p4python