diff --git a/automated/build-next.sh b/automated/build-next.sh index 270651a0..ebac9bdd 100755 --- a/automated/build-next.sh +++ b/automated/build-next.sh @@ -63,6 +63,7 @@ require_400_file "$HACKAGE_CREDS" mkdir -p $ROOT/bin BINDIR=$(cd $ROOT/bin ; pwd) ( +# See etc/curator-exes/README.md CURATOR_EXES=95a207fb4d5bd2e2a255350ce18f55976344eeb71e6f27a25f63e8dba28a4cd1 cd $BINDIR rm -f curator stack *.bz2 diff --git a/etc/curator-exes/.gitignore b/etc/curator-exes/.gitignore new file mode 100644 index 00000000..ae3c1726 --- /dev/null +++ b/etc/curator-exes/.gitignore @@ -0,0 +1 @@ +/bin/ diff --git a/etc/curator-exes/Dockerfile b/etc/curator-exes/Dockerfile new file mode 100644 index 00000000..81f4dbd9 --- /dev/null +++ b/etc/curator-exes/Dockerfile @@ -0,0 +1,13 @@ +FROM fpco/stack-build:lts-14 + +# Prime the snapshot so rebuilds are faster +RUN mkdir -p /artifacts +RUN stack update +RUN stack build --no-install-ghc --resolver lts-13.28 --only-dependencies stack amazonka-s3 + +RUN git clone --depth 1 https://github.com/commercialhaskell/stack && \ + git clone --depth 1 https://github.com/commercialhaskell/curator + +COPY stack.yaml . + +RUN stack --no-install-ghc install --local-bin-path /artifacts diff --git a/etc/curator-exes/README.md b/etc/curator-exes/README.md new file mode 100644 index 00000000..150f7bda --- /dev/null +++ b/etc/curator-exes/README.md @@ -0,0 +1,5 @@ +Scripts to create and upload the curator-exes.tar.bz2 files. Make sure to +update the hash in automated/build-next.sh. + +NOTE: Depending on what's exactly on the master branches when running the +`./run.sh` script, the `stack.yaml` file may need some tweaks. diff --git a/etc/curator-exes/run.sh b/etc/curator-exes/run.sh new file mode 100755 index 00000000..de90f644 --- /dev/null +++ b/etc/curator-exes/run.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env bash + +set -eux + +rm -rf bin +mkdir -p bin + +docker build . --tag curator-exes + +docker run --rm -v $(pwd)/bin:/output curator-exes cp /artifacts/* output +aws s3 cp curators-exes/* s3://download.fpcomplete.com/curator-exes/ diff --git a/etc/curator-exes/stack.yaml b/etc/curator-exes/stack.yaml new file mode 100644 index 00000000..08ac4d9e --- /dev/null +++ b/etc/curator-exes/stack.yaml @@ -0,0 +1,22 @@ +resolver: lts-13.28 + +packages: +- stack +- curator + +extra-deps: +- hi-file-parser-0.1.0.0@sha256:3fc95852035c8e0fa6d5f9d22e5108067c8f4816ac84675bddc971b20144a9ae,2317 +- http-download-0.1.0.0@sha256:b02d76d28364b74fb90d3ec3c46fd81f9d77bcf71fa40c1d341a7251a0fc40e8,2023 +- pantry-0.1.1.2@sha256:6f06556f8e934afd517559d6f3dae947db91ef3801ee4e5cee9916c83a0c4d52,4628 +- rio-prettyprint-0.1.0.0@sha256:764e1a357275c3c62d57c494d038feae01cf745788e7d0e97367ba793c9670c3,1359 +- ansi-terminal-0.9.1@sha256:48f53532d0f365ffa568c8cf0adc84c66f800a7d80d3329e4f04fa75392f4af1,3225 +- rio-0.1.12.0@sha256:a0b42682a455ffde6a4d894b135117e379aea7ed1810c2cfed471b8f5879968c,3633 +- unliftio-0.2.12@sha256:b089fbc2ff2628a963c2c4b12143f2020874e3e5144ffd6c62b25639a0ca1483,3325 + +- github: fpco/casa + commit: a0cd05c1a9ce33acbb1bdfb9324370f884916e88 + # sha256: 812e05de8f9abdbd1101fc94895dcfd5c35962c4d67a43cc20cbc06eb59ea1f0 + # size: 9508 + subdirs: + - casa-client + - casa-types