simplify packaging with docker

Small tweak to the docker CLI invokation when packaging to make it less
verbose.

Related: I6a9bc7d3686a1b116d664db77f072b004b30fd25
Sem-Ver: bugfix
Change-Id: Ida07b3b439949fe83066039350647901693d4816
This commit is contained in:
Vincent Llorens 2017-02-21 14:56:19 +01:00
parent 449f53f687
commit bf3f9e6895
5 changed files with 7 additions and 7 deletions

View File

@ -33,14 +33,14 @@ inside the synergy-service directory.
- launch the container
docker run -i -v /path/to/synergy-service:/tmp/synergy-service \
docker run -i -v /path/to/synergy-service:/tmp/synergy \
synergy-centos7-builder
You can override the package version that will be set during the packaging
process by adding `-e "PKG_VERSION=x.y.z"` to the above command line.
Otherwise, the package version will be set to the latest git tag.
This actually mount the synergy-service directory to `/tmp/synergy-service` on
This actually mount the synergy-service directory to `/tmp/synergy` on
the guest.
- the resulting rpm should be in the build directory if successful
@ -59,7 +59,7 @@ inside the synergy-service directory.
- launch the container
docker run -i -v /path/to/synergy-service:/tmp/synergy-service \
docker run -i -v /path/to/synergy-service:/tmp/synergy \
synergy-ubuntu14.04-builder
You can override the package version that will be set during the packaging

View File

@ -7,7 +7,7 @@ RUN yum install -y centos-release-openstack-liberty \
git-core \
&& yum update -y
RUN yum install -y python-pbr # Needs centos-release-openstack-* to be installed first
RUN mkdir /tmp/synergy-service
RUN mkdir /tmp/synergy
RUN useradd -m -p pkger pkger
USER pkger
COPY build.sh /home/pkger/

View File

@ -2,7 +2,7 @@
set -e -x
RPMBUILD=/home/pkger/rpmbuild
PKG_DIR=/tmp/synergy-service
PKG_DIR=/tmp/synergy
function get_version() {
if [[ -z $PKG_VERSION ]]; then

View File

@ -11,7 +11,7 @@ RUN apt-get update \
python-all \
python-pbr \
python-setuptools
RUN mkdir /tmp/synergy-service
RUN mkdir /tmp/synergy
RUN useradd -m -p pkger pkger
USER pkger
COPY build.sh /home/pkger/build.sh

View File

@ -1,7 +1,7 @@
#!/usr/bin/env bash
set -e -x
PKG_DIR=/tmp/synergy-service
PKG_DIR=/tmp/synergy
function copy_source() {
cd /home/pkger