blubber.yaml: Bump pipeline version
Use v4 for blubber 0.8.0 Bump helm chart version for limitconfig causing failing "helm test". Change-Id: I850990920748ad80b59093d188a529ae916dc3f2
|3 meses atrás|
|.pipeline||3 meses atrás|
|api/openapi-spec||4 meses atrás|
|build||1 ano atrás|
|cmd||4 meses atrás|
|config||4 meses atrás|
|docker||4 meses atrás|
|docs||10 meses atrás|
|meta||2 anos atrás|
|scripts||11 meses atrás|
|vendor||5 meses atrás|
|.gitignore||11 meses atrás|
|.gitreview||1 ano atrás|
|CONTRIBUTING.md||8 meses atrás|
|Gopkg.lock||5 meses atrás|
|Gopkg.toml||5 meses atrás|
|LICENSE||2 anos atrás|
|Makefile||4 meses atrás|
|README.md||4 meses atrás|
|VERSION||4 meses atrás|
|blubber.example.yaml||4 meses atrás|
|go.mod||8 meses atrás|
|policy.example.yaml||5 meses atrás|
Very experimental proof of concept.
Blubber is a highly opinionated abstraction for container build configurations and a command-line compiler which currently supports outputting multi-stage Dockerfiles. It aims to provide a handful of declarative constructs that accomplish build configuration in a more secure and determinate way than running ad-hoc commands.
version: v4 base: debian:jessie apt: packages: [libjpeg, libyaml] lives: in: /srv/service runs: environment: FOO: bar BAR: baz variants: build: apt: packages: [libjpeg-dev, libyaml-dev] node: requirements: [package.json, package-lock.json] copies: [local] development: includes: [build] test: includes: [build] apt: packages: [chromium] entrypoint: [npm, test] prep: includes: [build] node: env: production production: base: debian:jessie-slim node: env: production copies: [prep] entrypoint: [node, server.js]
Blubber supports a concept of composeable configuration variants for defining slightly different container images while still maintaining a sufficient degree of parity between them. For example, images for development and testing may require some development and debugging packages which you wouldn’t want in production lest they contain vulnerabilities and somehow end up linked or included in the application runtime.
Properties declared at the top level are shared among all variants unless
redefined, and one variant can include the properties of others. Some
apt:packages are combined when inherited or included.
In the example configuration, the
test variant when expanded effectively
version: v4 base: debian:jessie apt: packages: [libjpeg, libyaml, libjpeg-dev, libyaml-dev, chromium] node: dependencies: true runs: in: /srv/service as: runuser uid: 666 gid: 666 entrypoint: [npm, test]
When trying to ensure optimally sized Docker images for production, there’s a common pattern that has emerged which is essentially to use one image for building an application and copying the resulting build artifacts to another much more optimized image, using the latter for production.
The Docker community has responded to this need by implementing
multi-stage builds and Blubber
makes use of this with its
copies configuration property.
In the example configuration, the
production variant declares artifacts to
be copied over from the result of building the
blubber command will be produce
Dockerfile output for the
blubber config.yaml variant
You can see the result of the example configuration by cloning this repo and running (assuming you have go):
make ./bin/blubber blubber blubber.example.yaml development ./bin/blubber blubber blubber.example.yaml test ./bin/blubber blubber blubber.example.yaml production
If you’d like to make code contributions to Blubber, see CONTRIBUTING.md.