3 ms·
Is there a clean way to do reuse this for multistage builds? ``` FROM nixery.dev/shell/git/node14/python3.8 as debug_extras FROM our/production:1.2.3 COPY -
by lmeyerov 5y ago
Is there a clean way to do reuse this for multistage builds?
```
FROM nixery.dev/shell/git/node14/python3.8 as debug_extras
FROM our/production:1.2.3
COPY --from=debug_extras /nixstuff /ubuntu/stuff
RUN python -c "print('nice!')"
```
- hamandcheese 5y agoYou could copy over the nix store, though your path wouldn’t be set up correctly to find the programs you want.
- JamesSwift 5y agoIt depends on what you are trying to get out of the builder pattern. I think it wouldn't provide any benefit to you but hard to say without knowing exactly what you want to achieve. e.g. if you want to remove all the stuff that you aren't using then nix already does that with a GC