summaryrefslogtreecommitdiff
path: root/blubber.example.yaml
diff options
context:
space:
mode:
authorDan Duvall <dduvall@wikimedia.org>2018-08-06 10:40:03 -0700
committerDan Duvall <dduvall@wikimedia.org>2018-08-14 09:01:06 -0700
commit374976d445b605f2ea1618cc6d2c5006d046fa28 (patch)
treeaffd3e67b38463d15e7fc00bfc400130974732b8 /blubber.example.yaml
parente7ce38ca630ae04b748308a2a0986393d6555ffc (diff)
downloadblubber-374976d445b605f2ea1618cc6d2c5006d046fa28.tar.gz
Refactor builder to support file requirements and run pre-install
The builder configuration has proven useful for supporting generic pre-entrypoint commands such as dependency managers not otherwise supported by specific Blubber configuration. Adding additional `builder.requirements` config expands support for such commands by allowing the user to specify files that should be copied into the image before the builder command runs. To support this extra configuration, `builder` had to be changed from a simple string to a mapping. The builder command must now by given as `builder.command`. The pattern of creating parent directories, copying files, and executing one or more commands prior to the entrypoint has become a common one. Some of the implementation of this pattern was moved from `PythonConfig` into shared build macros `build.SortFilesByDir` and `build.SyncFiles`. All config types that must have requirements files copied over independently of the entire source tree (`PythonConfig`, `BuilderConfig`, `NodeConfig`) now delegate to these functions. Change-Id: I67f33034f22cee2851ec866cfb07ab20c23eba8c
Diffstat (limited to 'blubber.example.yaml')
-rw-r--r--blubber.example.yaml4
1 files changed, 3 insertions, 1 deletions
diff --git a/blubber.example.yaml b/blubber.example.yaml
index 1979ee5..bfb3a37 100644
--- a/blubber.example.yaml
+++ b/blubber.example.yaml
@@ -18,7 +18,9 @@ variants:
requirements: [package.json, package-lock.json]
python:
requirements: [requirements.txt]
- builder: [make, -f, Makefile]
+ builder:
+ command: [make, deps]
+ requirements: [Makefile, vendor]
development:
includes: [build]