-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Makefile: Implement support for fully sourced container stack HMS-3883
- Loading branch information
1 parent
f71175f
commit fc6bd00
Showing
4 changed files
with
48 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,3 +21,4 @@ coverage | |
|
||
*~ | ||
bots | ||
container_built.info |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
|
||
.PHONY: help | ||
help: | ||
@echo "make [TARGETS...]" | ||
@echo | ||
@echo "This is the maintenance makefile of osbuild-composer. The following" | ||
@echo "targets are available:" | ||
@echo | ||
@echo " help: Print this usage information." | ||
@echo " container: Build a container to run the frontend." | ||
@echo " Implicitly used by https://github.com/osbuild/osbuild-getting-started/" | ||
|
||
# either "docker" or "sudo podman" | ||
# podman needs to build as root as it also needs to run as root afterwards | ||
CONTAINER_EXECUTABLE ?= sudo podman | ||
|
||
DOCKER_IMAGE := image-builder-frontend_devel | ||
DOCKERFILE := distribution/Dockerfile | ||
|
||
# All files to check for rebuild! | ||
SRC_DEPS := $(shell find . -not -path './node_modules/*' -not -path './dist/*' -name "*.ts" -or -name "*.tsx" -or -name "*.yml" -or -name "*.yaml" -or -name "*.json" -or -name "*.js") | ||
|
||
clean: | ||
rm -f container_built.info | ||
|
||
container_built.info: $(DOCKERFILE) $(SRC_DEPS) | ||
$(CONTAINER_EXECUTABLE) build -t $(DOCKER_IMAGE) -f $(DOCKERFILE) . | ||
echo "Container last built on" > $@ | ||
date >> $@ | ||
|
||
.PHONY: container | ||
container: container_built.info |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters