This repository was archived by the owner on Apr 1, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +4
-14
lines changed
Expand file tree Collapse file tree 1 file changed +4
-14
lines changed Original file line number Diff line number Diff line change 11FROM haskell:8.6 as build
22WORKDIR /build
3- RUN cabal new-update
43
5- # Build our upstream dependencies after copying in only enough to tell cabal
6- # what they are. This will make these layers cache better even as we change the
7- # code of semantic itself.
8- COPY semantic.cabal .
9- COPY cabal.project .
10- COPY semantic-core/semantic-core.cabal ./semantic-core/
11- COPY vendor ./vendor
12- RUN cabal new-build --only-dependencies
4+ RUN cabal new-update
135
14- # Once the dependencies are built, copy in the rest of the code and compile
15- # semantic itself.
16- COPY . /build
17- RUN cabal new-build semantic:exe:semantic
6+ COPY . .
7+ RUN cabal new-build --flags="release" semantic:exe:semantic
188
199# A fake `install` target until we can get `cabal new-install` to work
20- RUN cp $(find dist-newstyle -name semantic -type f -perm -u=x) /usr/local/bin/semantic
10+ RUN cp $(find dist-newstyle/build/x86_64-linux -name semantic -type f -perm -u=x) /usr/local/bin/semantic
2111
2212# Create a fresh image containing only the compiled CLI program, so that the
2313# image isn't bulked up by all of the extra build state.
You can’t perform that action at this time.
0 commit comments