From a42ed3883b6ba0f2206c866ef43210eabdefc431 Mon Sep 17 00:00:00 2001 From: Valentin Rothberg Date: Wed, 11 Sep 2019 11:45:53 +0200 Subject: [PATCH] Add build-container make target To avoid regressing on the Dockerfile, run the new make target in the CI as well. Signed-off-by: Valentin Rothberg --- .travis.yml | 3 ++- Dockerfile | 2 +- Makefile | 5 +++++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 56d05f9..1a22440 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,7 +3,8 @@ sudo: required before_install: - sudo add-apt-repository ppa:projectatomic/ppa --yes - sudo apt-get update -qq - - sudo apt-get install -qq shellcheck skopeo + - sudo apt-get install -qq podman shellcheck skopeo script: - make validate + - make build-container diff --git a/Dockerfile b/Dockerfile index 94cbed7..b33ecd8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM fedora +FROM docker.io/library/fedora:latest RUN dnf install -y jq skopeo findutils file 'dnf-command(download)' diff --git a/Makefile b/Makefile index 59c9bce..95b526e 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,12 @@ SRC := ./BuildSourceImage.sh +CTR_IMAGE := localhost/containers/buildsourceimage all: validate .PHONY: validate validate: $(SRC) shellcheck -a $(SRC) + +.PHONY: build-container +build-container: Dockerfile + podman build -f Dockerfile -t $(CTR_IMAGE) .