Convert all of pkg/* to linuxkit pkg build

This was done with the following "script":

    git rm pkg/{auditd,binfmt,init}/Makefile
    sed -e 's/IMAGE=/image: /g' -i pkg/*/Makefile
    sed -e 's/NETWORK=1/network: true/g' -i pkg/*/Makefile
    sed -e 's/ARCHES=x86_64/arches:\n  - amd64/g' -i pkg/*/Makefile
    sed -e '/DEPS:\?=/d' -i pkg/*/Makefile
    sed -e '/ARCHES=SKIP/d' -i pkg/node_exporter/Makefile
    sed -e 's/include \.\.\/package.mk//g' -i pkg/*/Makefile
    sed -e '/^$/d' -i pkg/*/Makefile
    git mv pkg/node_exporter/Makefile pkg/node_exporter/build.yml-skip
    for i in pkg/*/Makefile ; do git mv $i ${i%Makefile}build.yml ; done

and manual update of pkg/Makefile.

Signed-off-by: Ian Campbell <ijc@docker.com>
This commit is contained in:
Ian Campbell 2017-10-09 16:17:24 +01:00
parent c889f13251
commit fc3e659f0e
61 changed files with 59 additions and 184 deletions

View File

@ -1,23 +1,19 @@
DIRS = $(shell find . -maxdepth 1 -mindepth 1 -type d)
DIRS = $(dir $(shell find . -maxdepth 2 -mindepth 2 -type f -name build.yml))
.PHONY: push force-push tag forcetag show-tag clean
# TODO(ijc) once all switch to `linuxkit pkg` update this to:
# linuxkit pkg <build|push> [--force] $$d
# linuxkit pkg show-tag $$d
push:
@set -e; for d in $(DIRS); do make -C "$$d" push; done
@set -e; for d in $(DIRS); do linuxkit pkg push "$$d"; done
forcepush:
@set -e; for d in $(DIRS); do make -C "$$d" forcepush; done
@set -e; for d in $(DIRS); do linuxkit pkg push --force "$$d"; done
tag:
@set -e; for d in $(DIRS); do make -C "$$d" tag; done
@set -e; for d in $(DIRS); do linuxkit pkg build "$$d"; done
forcetag:
@set -e; for d in $(DIRS); do make -C "$$d" forcetag; done
@set -e; for d in $(DIRS); do linuxkit pkg build --force "$$d"; done
show-tag:
@set -e; for d in $(DIRS); do make -C "$$d" show-tag; done
@set -e; for d in $(DIRS); do linuxkit pkg show-tag "$$d"; done
clean:

View File

@ -1,3 +0,0 @@
IMAGE=acpid
include ../package.mk

1
pkg/acpid/build.yml Normal file
View File

@ -0,0 +1 @@
image: acpid

View File

@ -1,16 +0,0 @@
.PHONY: push forcepush tag forcetag show-tag
push:
linuxkit pkg push .
forcepush:
linuxkit pkg push --force .
tag:
linuxkit pkg build .
forcetag:
linuxkit pkg build --force .
show-tag:
linuxkit pkg show-tag .

View File

@ -1,16 +0,0 @@
.PHONY: push forcepush tag forcetag show-tag
push:
linuxkit pkg push .
forcepush:
linuxkit pkg push --force .
tag:
linuxkit pkg build .
forcetag:
linuxkit pkg build --force .
show-tag:
linuxkit pkg show-tag .

View File

@ -1,3 +0,0 @@
IMAGE=ca-certificates
include ../package.mk

View File

@ -0,0 +1 @@
image: ca-certificates

View File

@ -1,4 +0,0 @@
IMAGE=containerd
DEPS=$(wildcard cmd/service/*.go) etc/containerd/config.toml
include ../package.mk

1
pkg/containerd/build.yml Normal file
View File

@ -0,0 +1 @@
image: containerd

View File

@ -1,4 +0,0 @@
IMAGE=dhcpcd
DEPS=dhcpcd.conf $(wildcard usr/lib/dhcpcd/dhcpcd-hooks/*)
include ../package.mk

1
pkg/dhcpcd/build.yml Normal file
View File

@ -0,0 +1 @@
image: dhcpcd

View File

@ -1,4 +0,0 @@
IMAGE=extend
DEPS=extend.go
include ../package.mk

1
pkg/extend/build.yml Normal file
View File

@ -0,0 +1 @@
image: extend

View File

@ -1,4 +0,0 @@
IMAGE=format
DEPS=format.go
include ../package.mk

1
pkg/format/build.yml Normal file
View File

@ -0,0 +1 @@
image: format

View File

@ -1,4 +0,0 @@
IMAGE=getty
DEPS=usr/bin/rungetty.sh $(wildcard etc/*) $(wildcard etc/init.d/*)
include ../package.mk

1
pkg/getty/build.yml Normal file
View File

@ -0,0 +1 @@
image: getty

View File

@ -1,6 +0,0 @@
IMAGE=host-timesync-daemon
DEPS=$(wildcard *.go)
NETWORK=1
ARCHES=x86_64
include ../package.mk

View File

@ -0,0 +1,4 @@
image: host-timesync-daemon
network: true
arches:
- amd64

View File

@ -1,5 +0,0 @@
IMAGE=init-lcow
NETWORK=1
ARCHES=x86_64
include ../package.mk

4
pkg/init-lcow/build.yml Normal file
View File

@ -0,0 +1,4 @@
image: init-lcow
network: true
arches:
- amd64

View File

@ -1,16 +0,0 @@
.PHONY: push forcepush tag forcetag show-tag
push:
linuxkit pkg push .
forcepush:
linuxkit pkg push --force .
tag:
linuxkit pkg build .
forcetag:
linuxkit pkg build --force .
show-tag:
linuxkit pkg show-tag .

View File

@ -1,4 +0,0 @@
IMAGE=ip
NETWORK=1
include ../package.mk

2
pkg/ip/build.yml Normal file
View File

@ -0,0 +1,2 @@
image: ip
network: true

View File

@ -1,4 +0,0 @@
IMAGE=metadata
DEPS=$(wildcard *.go)
include ../package.mk

1
pkg/metadata/build.yml Normal file
View File

@ -0,0 +1 @@
image: metadata

View File

@ -1,5 +0,0 @@
IMAGE=mkimage
DEPS=mkimage.sh
ARCHES=x86_64
include ../package.mk

3
pkg/mkimage/build.yml Normal file
View File

@ -0,0 +1,3 @@
image: mkimage
arches:
- amd64

View File

@ -1,3 +0,0 @@
IMAGE=modprobe
include ../package.mk

1
pkg/modprobe/build.yml Normal file
View File

@ -0,0 +1 @@
image: modprobe

View File

@ -1,4 +0,0 @@
IMAGE=mount
DEPS=mountie.go
include ../package.mk

1
pkg/mount/build.yml Normal file
View File

@ -0,0 +1 @@
image: mount

View File

@ -1,6 +1,3 @@
IMAGE=node_exporter
image: node_exporter
# Can't pull with content trust. Skip for now
# https://github.com/linuxkit/linuxkit/issues/2349
ARCHES=SKIP
include ../package.mk

View File

@ -1,4 +0,0 @@
IMAGE=open-vm-tools
ARCHES=x86_64
include ../package.mk

View File

@ -0,0 +1,3 @@
image: open-vm-tools
arches:
- amd64

View File

@ -1,4 +0,0 @@
IMAGE=openntpd
DEPS=etc/ntpd.conf
include ../package.mk

1
pkg/openntpd/build.yml Normal file
View File

@ -0,0 +1 @@
image: openntpd

View File

@ -1,3 +0,0 @@
IMAGE=qemu-ga
include ../package.mk

1
pkg/qemu-ga/build.yml Normal file
View File

@ -0,0 +1 @@
image: qemu-ga

View File

@ -1,4 +0,0 @@
IMAGE=rngd
DEPS:=$(wildcard cmd/rngd/*.go) $(shell find cmd/rngd/vendor)
include ../package.mk

1
pkg/rngd/build.yml Normal file
View File

@ -0,0 +1 @@
image: rngd

View File

@ -1,4 +0,0 @@
IMAGE=runc
NETWORK=1
include ../package.mk

2
pkg/runc/build.yml Normal file
View File

@ -0,0 +1,2 @@
image: runc
network: true

View File

@ -1,4 +0,0 @@
IMAGE=sshd
DEPS=etc/motd etc/ssh/sshd_config usr/bin/ssh.sh
include ../package.mk

1
pkg/sshd/build.yml Normal file
View File

@ -0,0 +1 @@
image: sshd

View File

@ -1,4 +0,0 @@
IMAGE=swap
DEPS=swap.sh
include ../package.mk

1
pkg/swap/build.yml Normal file
View File

@ -0,0 +1 @@
image: swap

View File

@ -1,4 +0,0 @@
IMAGE=sysctl
DEPS=main.go
include ../package.mk

1
pkg/sysctl/build.yml Normal file
View File

@ -0,0 +1 @@
image: sysctl

View File

@ -1,4 +0,0 @@
IMAGE=sysfs
DEPS=main.go
include ../package.mk

1
pkg/sysfs/build.yml Normal file
View File

@ -0,0 +1 @@
image: sysfs

View File

@ -1,4 +0,0 @@
IMAGE=trim-after-delete
DEPS=$(wildcard *.go)
include ../package.mk

View File

@ -0,0 +1 @@
image: trim-after-delete

View File

@ -1,7 +0,0 @@
IMAGE=tss
NETWORK=1
DEPS=$(wildcard upload/out/*) $(wildcard upload/out/etc/*) $(wildacrd upload/src/savedeps/*) $(wildcard upload/src/glibc_stubs/*)
ARCHES=x86_64
include ../package.mk

4
pkg/tss/build.yml Normal file
View File

@ -0,0 +1,4 @@
image: tss
network: true
arches:
- amd64

View File

@ -1,7 +0,0 @@
IMAGE=vpnkit-expose-port
DEPS=$(wildcard *.go)
NETWORK=1
ARCHES=x86_64
include ../package.mk

View File

@ -0,0 +1,4 @@
image: vpnkit-expose-port
network: true
arches:
- amd64

View File

@ -1,6 +0,0 @@
IMAGE=vpnkit-forwarder
DEPS=$(wildcard *.go)
NETWORK=1
ARCHES=x86_64
include ../package.mk

View File

@ -0,0 +1,4 @@
image: vpnkit-forwarder
network: true
arches:
- amd64

View File

@ -1,6 +0,0 @@
IMAGE=vsudd
DEPS=$(wildcard *.go)
NETWORK=1
ARCHES=x86_64
include ../package.mk

4
pkg/vsudd/build.yml Normal file
View File

@ -0,0 +1,4 @@
image: vsudd
network: true
arches:
- amd64