From f5ddf1062e90cc81bed2721cf48ef7e09812fdc9 Mon Sep 17 00:00:00 2001 From: gdm85 Date: Sat, 26 Sep 2015 10:02:51 +0200 Subject: [PATCH] Imported rkt-images into tenku --- rkt/.gitignore | 1 + rkt/Makefile | 22 ++++++++++++++++++++++ rkt/README.md | 28 ++++++++++++++++++++++++++++ rkt/nginx/Makefile | 13 +++++++++++++ rkt/nginx/build.manifest | 38 ++++++++++++++++++++++++++++++++++++++ 5 files changed, 102 insertions(+) create mode 100644 rkt/.gitignore create mode 100644 rkt/Makefile create mode 100644 rkt/README.md create mode 100644 rkt/nginx/Makefile create mode 100644 rkt/nginx/build.manifest diff --git a/rkt/.gitignore b/rkt/.gitignore new file mode 100644 index 0000000..337b8dc --- /dev/null +++ b/rkt/.gitignore @@ -0,0 +1 @@ +nginx/nginx.aci diff --git a/rkt/Makefile b/rkt/Makefile new file mode 100644 index 0000000..2fb6c99 --- /dev/null +++ b/rkt/Makefile @@ -0,0 +1,22 @@ +## define here all recursively buildable targets +SUBDIRS := nginx + +.PHONY := $(SUBDIRS) recurse clean get-tools +.DEFAULT_GOAL := recurse + +RECURSE_TARGET ?= $(MAKECMDGOALS) + +recurse: + @for D in $(SUBDIRS) ; do \ + if [ -e $${D}/Makefile ]; then \ + $(MAKE) -C "$${D}" $(RECURSE_TARGET) || exit $$? ; \ + fi ; \ + done + +clean: ; @$(MAKE) RECURSE_TARGET=clean recurse + +## disable entering/exiting messages +#.SILENT: + +get-tools: + go get github.com/gdm85/deb2aci diff --git a/rkt/README.md b/rkt/README.md new file mode 100644 index 0000000..b007c8f --- /dev/null +++ b/rkt/README.md @@ -0,0 +1,28 @@ +rkt images +========== + +This repository contains recipes for various [ACI](https://github.com/appc/spec/blob/master/spec/aci.md) images that can be used with [rkt](https://github.com/coreos/rkt). + +Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 2.0 Generic License. + +Building +======== + +You will need [deb2aci](https://github.com/gdm85/deb2aci) to build these ACI images; you can fetch it automatically into your ``GOPATH`` with: +``` +make get-tools +``` + +To build all images, run: +``` +make +``` + +To build a specific image, for example ``nginx``, run: +``` +make -C nginx +``` + +**DO NOT** run ``make nginx``, it would not build anything. + +Each image subdirectory comes with a README.md for specific documentation and instructions. diff --git a/rkt/nginx/Makefile b/rkt/nginx/Makefile new file mode 100644 index 0000000..fc9122b --- /dev/null +++ b/rkt/nginx/Makefile @@ -0,0 +1,13 @@ +.DEFAULT_GOAL := all +.PHONY := all clean + +## all necessary deb packages +DEBS := nginx + +all: nginx.aci + +nginx.aci: + deb2aci -pkg $(DEBS) -manifest build.manifest -image $@ + +clean: + rm -f nginx.aci diff --git a/rkt/nginx/build.manifest b/rkt/nginx/build.manifest new file mode 100644 index 0000000..93b666e --- /dev/null +++ b/rkt/nginx/build.manifest @@ -0,0 +1,38 @@ +{ + "acKind": "ImageManifest", + "acVersion": "0.6.1", + "name": "gdm85/rkt-images/nginx", + "app":{ + "user": "65534", + "group": "65534", + "exec":[ + "/usr/sbin/nginx" + ], + "mountPoints": [ + { + "name": "etc", + "path": "/etc/nginx", + "readOnly": true + }, + { + "name": "www", + "path": "/var/www", + "readOnly": true + } + ], + "ports": [ + { + "name": "www", + "port": 80, + "protocol": "tcp", + "socketActivated": false + } + ] + }, + "annotations":[ + { + "name":"authors", + "value":"gdm85 " + } + ] +}