From b4fbab4b567b2a7cba42f006bcc87f75c33e8474 Mon Sep 17 00:00:00 2001 From: Ben Firshman Date: Tue, 30 Sep 2014 11:54:13 -0700 Subject: [PATCH] Run pyinstaller build as normal user ... and test build on CI so we don't break it again! Fixes #503 Signed-off-by: Ben Firshman --- Dockerfile | 3 +++ script/build-linux | 4 ++-- wercker.yml | 3 +++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index c448b8c16..cc6b9990e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,6 @@ FROM debian:wheezy RUN apt-get update -qq && apt-get install -qy python python-pip python-dev git && apt-get clean +RUN useradd -d /home/user -m -s /bin/bash user WORKDIR /code/ ADD requirements.txt /code/ @@ -10,3 +11,5 @@ RUN pip install -r requirements-dev.txt ADD . /code/ RUN python setup.py install + +RUN chown -R user /code/ diff --git a/script/build-linux b/script/build-linux index c30dbfbd7..e16f2fb51 100755 --- a/script/build-linux +++ b/script/build-linux @@ -3,5 +3,5 @@ set -ex mkdir -p `pwd`/dist chmod 777 `pwd`/dist docker build -t fig . -docker run -v `pwd`/dist:/code/dist fig pyinstaller -F bin/fig -docker run -v `pwd`/dist:/code/dist fig dist/fig --version +docker run -u user -v `pwd`/dist:/code/dist fig pyinstaller -F bin/fig +docker run -u user -v `pwd`/dist:/code/dist fig dist/fig --version diff --git a/wercker.yml b/wercker.yml index 6ab2d95e9..96fb22b57 100644 --- a/wercker.yml +++ b/wercker.yml @@ -7,3 +7,6 @@ build: - script: name: run tests code: script/test + - script: + name: build binary + code: script/build-linux