@@ -137,3 +137,34 @@ jobs:
137
137
COMPILER_NIX_NAME=${{ inputs.compiler-nix-name }}
138
138
MINIMAL=${{ inputs.minimal }}
139
139
IOG=${{ inputs.iog }}
140
+
141
+ codespace-download :
142
+ env :
143
+ IMAGE_NAME : input-output-hk/devx-devcontainer
144
+ needs : codespace-upload
145
+ permissions :
146
+ packages : write
147
+ runs-on : ubuntu-latest
148
+ # We want a GitHub Codespace image for each combination of devx developer shell option.
149
+ # But, since the purpose of GitHub Codespace is to serve a complete development environment,
150
+ # the user is likely to always expect HLS (I don't see the point otherwise).
151
+ # Therefore, it doesn't seem useful to build an image on the `-minimal` flavor (without HLS),
152
+ # or the `-static` one (especially since the latter currently requires `-minimal` to work).
153
+ # Likely, we consider using `-iog` as the default and do not generate other images.
154
+ # Then the user choices left would be between native, `-windows` or `-js` target platforms,
155
+ # and the GHC version (currently `ghc810` and `ghc96`).
156
+ if : ${{ contains(fromJSON('["x86_64-linux", "aarch64-linux"]'), inputs.platform) && contains(fromJson('["","-windows","-js"]'), inputs.target-platform) && contains(fromJson('["ghc810","ghc96"]'), inputs.compiler-nix-name) && !inputs.minimal && inputs.iog }}
157
+ steps :
158
+ - name : Checkout repository
159
+ uses : actions/checkout@v3
160
+
161
+ - name : Log in to the Container registry
162
+
163
+ with :
164
+ registry : ${{ env.REGISTRY }}
165
+ username : ${{ github.actor }}
166
+ password : ${{ secrets.GITHUB_TOKEN }}
167
+
168
+ - name : Run test command inside the Dev Container
169
+ run : docker run --rm ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ inputs.platform }}.${{ inputs.compiler-nix-name }}${{ inputs.target-platform }}-iog \
170
+ /bin/bash -c "cabal update && cabal unpack hello && cd hello-* && cabal build"
0 commit comments