mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-07-22 18:41:37 +00:00
Merge pull request #1008 from justincormack/ocaml-hub
Build OCaml iptables package once and push to hub
This commit is contained in:
commit
c8562d29ec
12
alpine/base/pinata-iptables/Makefile
Normal file
12
alpine/base/pinata-iptables/Makefile
Normal file
@ -0,0 +1,12 @@
|
||||
BASE=ocaml/opam:alpine
|
||||
IMAGE=pinata-iptables
|
||||
|
||||
# OCaml builds are non deterministic so do not generate a hash
|
||||
|
||||
default: Dockerfile main.ml
|
||||
docker pull $(BASE)
|
||||
BUILD=$$( docker build -q . ) && \
|
||||
[ -n "$$BUILD" ] && \
|
||||
echo "Built $$BUILD" && \
|
||||
docker tag $$BUILD mobylinux/$(IMAGE):latest
|
||||
docker push mobylinux/$(IMAGE):latest
|
2
alpine/packages/iptables/.gitignore
vendored
2
alpine/packages/iptables/.gitignore
vendored
@ -1 +1 @@
|
||||
iptables
|
||||
usr
|
||||
|
@ -1,11 +1,13 @@
|
||||
# This image is currently just tagged latest as non reproducible
|
||||
IPTABLES_IMAGE=mobylinux/pinata-iptables@sha256:4dc27c9515c99dc80c8ec431de2c7db7d382425e5c1de13a560e6ec4c6a52b89
|
||||
|
||||
all: usr/local/sbin/iptables
|
||||
|
||||
usr/local/sbin/iptables: Dockerfile main.ml
|
||||
mkdir -p usr/local/sbin
|
||||
BUILD=$$( docker build -q . ) && \
|
||||
[ -n "$$BUILD" ] && \
|
||||
echo "Built $$BUILD" && \
|
||||
docker run --rm $$BUILD | tar xf - -C usr/local/sbin
|
||||
usr/local/sbin/iptables:
|
||||
mkdir -p $(dir $@)
|
||||
docker run --rm --net=none --log-driver=none $(IPTABLES_IMAGE) | tar xf - -C $(dir $@)
|
||||
|
||||
clean:
|
||||
rm -rf usr
|
||||
|
||||
.DELETE_ON_ERROR:
|
||||
|
Loading…
Reference in New Issue
Block a user