From #38 (comment):
I'm considering reverting this change, as fava-portfolio-returns depends on beangrow, which in turn depends on scipy. As the results of that dependency, the fava docker image is ballooning from ~60MiB to ~150MiB (with the uncompressed image to ~500MiB when inspected using https://github.com/wagoodman/dive).
Maybe it's better to build with this dependency with vxxx-extras and latest-extras labels, so that people can choose between a minimum setup and a full-featured setup. But I'm not sure how to do that the best with a combination of the Dockerfile and the actions workflow....
I like it! Here's what I'm thinking: We can use build variables for this.
- In the github workflow, add a matrix for two
build_variant options - normal and extras.
- In the
Build and push Docker image step:
- Set the
tags to conditionally add -extras as appropriate.
- Add
build-args: [BUILD_VARIANT=${{ matrix.build_variant }}]
- Split
requirements.txt so some of it is in requirements-extra.txt.
- In
Dockerfile, add ARG BUILD_VARIANT. Only perform the extra pip3 install steps for the extra variant.
What do you think?
From #38 (comment):
I like it! Here's what I'm thinking: We can use build variables for this.
build_variantoptions -normalandextras.Build and push Docker imagestep:tagsto conditionally add-extrasas appropriate.build-args: [BUILD_VARIANT=${{ matrix.build_variant }}]requirements.txtso some of it is inrequirements-extra.txt.Dockerfile, addARG BUILD_VARIANT. Only perform the extrapip3 installsteps for theextravariant.What do you think?