view contrib/dockerrpm @ 21833:c1ceec0c8cb4

patch: use ctx.node() instead of bare node variable Future patches will allow patch.diff to take a basectx so node1 (and node2) could make hexfunc error out. Instead, we'll call the node function on the context object directly.
author Sean Farley <sean.michael.farley@gmail.com>
date Wed, 14 Aug 2013 13:10:27 -0500
parents 76a347bcdb33
children f5abb231b80a
line wrap: on
line source

#!/bin/bash

BUILDDIR=$(dirname $0)
ROOTDIR=$(cd $BUILDDIR/..; pwd)

if which docker.io >> /dev/null ; then
  DOCKER=docker.io
elif which docker >> /dev/null ; then
  DOCKER=docker
fi

$DOCKER build --tag "hg-dockerrpm-$1" - < $BUILDDIR/docker/$1
$DOCKER run --rm -v $ROOTDIR:/hg "hg-dockerrpm-$1" bash -c \
    "cp -a hg hg-build; cd hg-build; make clean local $1; cp packages/$1/* /hg/packages/$1/"