Cleaning up/improving docker performance
This commit is contained in:
parent
f021ede843
commit
5ef85e402e
@ -33,6 +33,6 @@ fi
|
||||
#This will take a long time the first time
|
||||
for IMAGE_DIR in "${IMAGE_DIRS[@]}"; do
|
||||
echo Docker building ${IMAGE_DIR}
|
||||
$SUDO docker build -t $(basename ${IMAGE_DIR}) -f ${IMAGE_DIR}/Dockerfile ${CUR_DIR}
|
||||
$SUDO docker build -t git-lfs/$(basename ${IMAGE_DIR}) -f ${IMAGE_DIR}/Dockerfile ${CUR_DIR}
|
||||
done
|
||||
|
||||
|
@ -4,7 +4,6 @@ MAINTAINER Andy Neff <andyneff@users.noreply.github.com>
|
||||
#Docker RUN example, pass in the git-lfs checkout copy you are working with
|
||||
LABEL RUN="docker run -v git-lfs-repo-dir:/src" -v repo_dir:/repo"
|
||||
|
||||
|
||||
RUN yum install -y createrepo rsync gnupg gnupg2 expect
|
||||
|
||||
#Add the simple build repo script
|
||||
|
@ -4,7 +4,6 @@ MAINTAINER Andy Neff <andyneff@users.noreply.github.com>
|
||||
#Docker RUN example, pass in the git-lfs checkout copy you are working with
|
||||
LABEL RUN="docker run -v git-lfs-repo-dir:/src" -v repo_dir:/repo"
|
||||
|
||||
|
||||
RUN yum install -y createrepo rsync expect
|
||||
|
||||
#Add the simple build repo script
|
||||
|
@ -4,7 +4,6 @@ MAINTAINER Andy Neff <andyneff@users.noreply.github.com>
|
||||
#Docker RUN example, pass in the git-lfs checkout copy you are working with
|
||||
LABEL RUN="docker run -v git-lfs-repo-dir:/src" -v repo_dir:/repo"
|
||||
|
||||
|
||||
RUN yum install -y createrepo rsync rpm-sign expect
|
||||
|
||||
#Add the simple build repo script
|
||||
|
@ -4,9 +4,9 @@ MAINTAINER Andy Neff <andyneff@users.noreply.github.com>
|
||||
#Docker RUN example, pass in the git-lfs checkout copy you are working with
|
||||
LABEL RUN="docker run -v git-lfs-repo-dir:/src -v repo_dir:/repo"
|
||||
|
||||
#TODO: Merge these two into one
|
||||
RUN yum install -y epel-release
|
||||
RUN yum install -y createrepo rsync git gnupg gnupg2 expect
|
||||
RUN yum install -y epel-release && \
|
||||
yum install -y createrepo rsync git gnupg gnupg2 expect
|
||||
|
||||
|
||||
#The purpose of this is to build and install everything needed to build git-lfs
|
||||
#Next time. So that the LONG build/installed in centos are only done once, and
|
||||
@ -17,13 +17,13 @@ RUN yum install -y createrepo rsync git gnupg gnupg2 expect
|
||||
ENV DOCKER_LFS_BUILD_VERSION=v0.5.3
|
||||
|
||||
ADD https://github.com/github/git-lfs/archive/${DOCKER_LFS_BUILD_VERSION}.tar.gz /tmp/docker_setup/
|
||||
#TODO: Merge these RUN commands into one to save docker container image space
|
||||
RUN cd /tmp/docker_setup/; \
|
||||
tar zxf ${DOCKER_LFS_BUILD_VERSION}.tar.gz
|
||||
RUN cd /tmp/docker_setup/git-lfs-*/rpm; \
|
||||
tar zxf ${DOCKER_LFS_BUILD_VERSION}.tar.gz; \
|
||||
cd /tmp/docker_setup/git-lfs-*/rpm; \
|
||||
touch build.log; \
|
||||
tail -f build.log & ./build_rpms.bsh; \
|
||||
pkill tail
|
||||
pkill tail; \
|
||||
rm -rvf /tmp/docker_setup/git-lfs-*/rpm/BUILD*
|
||||
#TODO: REMOVE this line after docker-scripts is merged into a release
|
||||
RUN yum install -y --nogpgcheck /tmp/docker_setup/git-lfs-*/rpm/RPMS/noarch/golang-pkg-linux-386-1*.noarch.rpm
|
||||
RUN rm -rf /tmp/docker_setup
|
||||
|
@ -4,8 +4,9 @@ MAINTAINER Andy Neff <andyneff@users.noreply.github.com>
|
||||
#Docker RUN example, pass in the git-lfs checkout copy you are working with
|
||||
LABEL RUN="docker run -v git-lfs-repo-dir:/src -v repo_dir:/repo"
|
||||
|
||||
RUN yum install -y epel-release
|
||||
RUN yum install -y createrepo rsync golang tar gnupg2 expect golang-pkg-linux-386.noarch
|
||||
RUN yum install -y epel-release && \
|
||||
yum install -y createrepo rsync golang tar gnupg2 expect \
|
||||
golang-pkg-linux-386.noarch
|
||||
|
||||
#The purpose of this is to build and install everything needed to build git-lfs
|
||||
#Next time. So that the LONG build/installed in centos are only done once, and
|
||||
@ -17,13 +18,16 @@ ENV DOCKER_LFS_BUILD_VERSION=v0.5.3
|
||||
|
||||
ADD https://github.com/github/git-lfs/archive/${DOCKER_LFS_BUILD_VERSION}.tar.gz /tmp/docker_setup/
|
||||
RUN cd /tmp/docker_setup/; \
|
||||
tar zxf ${DOCKER_LFS_BUILD_VERSION}.tar.gz
|
||||
RUN cd /tmp/docker_setup/git-lfs-*/rpm; \
|
||||
tar zxf ${DOCKER_LFS_BUILD_VERSION}.tar.gz; \
|
||||
cd /tmp/docker_setup/git-lfs-*/rpm; \
|
||||
touch build.log; \
|
||||
tail -f build.log & ./build_rpms.bsh; \
|
||||
pkill tail
|
||||
pkill tail; \
|
||||
rm -rvf /tmp/docker_setup/git-lfs-*/rpm/BUILD*
|
||||
RUN rm -rf /tmp/docker_setup
|
||||
|
||||
|
||||
|
||||
#Add the simple build repo script
|
||||
COPY rpm_sign.exp signing.key centos_script.bsh /tmp/
|
||||
|
||||
|
@ -4,7 +4,6 @@ MAINTAINER Andy Neff <andyneff@users.noreply.github.com>
|
||||
#Docker RUN example, pass in the git-lfs checkout copy you are working with
|
||||
LABEL RUN="docker run -v git-lfs-repo-dir:/src -v repo_dir:/repo"
|
||||
|
||||
|
||||
RUN yum install -y createrepo rsync git ruby ruby-devel golang \
|
||||
gnupg2 rpm-sign expect \
|
||||
golang-pkg-linux-386.noarch
|
||||
@ -19,13 +18,16 @@ ENV DOCKER_LFS_BUILD_VERSION=v0.5.3
|
||||
|
||||
ADD https://github.com/github/git-lfs/archive/${DOCKER_LFS_BUILD_VERSION}.tar.gz /tmp/docker_setup/
|
||||
RUN cd /tmp/docker_setup/; \
|
||||
tar zxf ${DOCKER_LFS_BUILD_VERSION}.tar.gz
|
||||
RUN cd /tmp/docker_setup/git-lfs-*/rpm; \
|
||||
tar zxf ${DOCKER_LFS_BUILD_VERSION}.tar.gz; \
|
||||
cd /tmp/docker_setup/git-lfs-*/rpm; \
|
||||
touch build.log; \
|
||||
tail -f build.log & ./build_rpms.bsh; \
|
||||
pkill tail
|
||||
pkill tail; \
|
||||
rm -rvf /tmp/docker_setup/git-lfs-*/rpm/BUILD*
|
||||
RUN rm -rf /tmp/docker_setup
|
||||
|
||||
|
||||
|
||||
#Add the simple build repo script
|
||||
COPY rpm_sign.exp signing.key centos_script.bsh /tmp/
|
||||
|
||||
|
@ -99,6 +99,6 @@ for DOCKER_FILE in "${IMAGES[@]}"; do
|
||||
-e REPO_HOSTNAME=${REPO_HOSTNAME:-git-lfs.github.com} \
|
||||
-v ${REPO_DIR}:/src \
|
||||
-v ${IMAGE_REPO_DIR}:/repo \
|
||||
${IMAGE_NAME} ${DOCKER_CMD-}
|
||||
git-lfs/${IMAGE_NAME} ${DOCKER_CMD-}
|
||||
|
||||
done
|
||||
|
Loading…
Reference in New Issue
Block a user