@@ -57,16 +57,17 @@ jobs:
57 - name: Upload compaREST Github Action Image
57 - name: Upload compaREST Github Action Image
58 uses: actions/upload-artifact@v2
58 uses: actions/upload-artifact@v2
60− name: compaREST-Github-Action-image
60+ name: compaREST Github Action Docker Image
61 path: compaREST-Github-Action-image.tar.gz
61 path: compaREST-Github-Action-image.tar.gz
63 - name: Upload compaREST Image
63 - name: Upload compaREST Image
64 uses: actions/upload-artifact@v2
64 uses: actions/upload-artifact@v2
66− name: compaREST-image
66+ name: compaREST Docker Image
67 path: compaREST-image.tar.gz
67 path: compaREST-image.tar.gz
69 - name: Install skopeo
69 - name: Install skopeo
70+ if: github.event_name == 'release'
70 shell: bash
71 shell: bash
72 sudo apt-get -y update
73 sudo apt-get -y update
@@ -83,8 +84,35 @@ jobs:
83 if: github.event_name == 'release'
84 if: github.event_name == 'release'
84 shell: bash
85 shell: bash
86− skopeo copy docker-archive:$(nix-build -A compaRESTGithubAction -j auto) docker://typeable/comparest-github-action:${{ github.event.payload.name }}
87+ skopeo copy docker-archive:$(nix-build -A compaRESTGithubAction -j auto) docker://typeable/comparest-github-action:${{ github.event.release.tag_name }}
87− skopeo copy docker-archive:$(nix-build -A compaRESTImage -j auto) docker://typeable/comparest:${{ github.event.payload.name }}
88+ skopeo copy docker-archive:$(nix-build -A compaRESTImage -j auto) docker://typeable/comparest:${{ github.event.release.tag_name }}
90+ - name: Upload compaREST Github Action Docker Image to release
91+ if: github.event_name == 'release'
92+ uses: svenstaro/upload-release-action@2.2.1
94+ repo_token: ${{ secrets.GITHUB_TOKEN }}
95+ file: compaREST-Github-Action-image.tar.gz
96+ asset_name: compaREST Github Action Docker Image
97+ tag: ${{ github.ref }}
99+ - name: Upload compaREST Docker Image to release
100+ if: github.event_name == 'release'
101+ uses: svenstaro/upload-release-action@2.2.1
103+ repo_token: ${{ secrets.GITHUB_TOKEN }}
104+ file: compaREST-image.tar.gz
105+ asset_name: compaREST Docker Image
106+ tag: ${{ github.ref }}
108+ - name: Upload compaREST binary – Linux – x86 to release
109+ if: github.event_name == 'release'
110+ uses: svenstaro/upload-release-action@2.2.1
112+ repo_token: ${{ secrets.GITHUB_TOKEN }}
114+ asset_name: compaREST binary – Linux – x86
115+ tag: ${{ github.ref }}
89 - name: Cache Nix post
117 - name: Cache Nix post
90 uses: ./.github/actions/nix_cache_post
118 uses: ./.github/actions/nix_cache_post
@@ -112,9 +140,18 @@ jobs:
112 - name: Upload macOS compaREST bundle
140 - name: Upload macOS compaREST bundle
113 uses: actions/upload-artifact@v2
141 uses: actions/upload-artifact@v2
115− name: compaREST-macOS
143+ name: compaREST binary – macOS – x86
116 path: compaREST
144 path: compaREST
146+ - name: Upload compaREST binary – macOS – x86 to release
147+ if: github.event_name == 'release'
148+ uses: svenstaro/upload-release-action@2.2.1
150+ repo_token: ${{ secrets.GITHUB_TOKEN }}
152+ asset_name: compaREST binary – macOS – x86
153+ tag: ${{ github.ref }}
118 - name: Cache Nix post
155 - name: Cache Nix post
119 uses: ./.github/actions/nix_cache_post
156 uses: ./.github/actions/nix_cache_post
@@ -150,17 +187,20 @@ jobs:
151 cp -LR $(nix-build -A WindowsCompaRESTBin -j auto)/bin compaREST
188 cp -LR $(nix-build -A WindowsCompaRESTBin -j auto)/bin compaREST
153− - name: Upload compaREST Linux Binary
190+ - name: Upload Windows compaREST bundle
154 uses: actions/upload-artifact@v2
191 uses: actions/upload-artifact@v2
156− name: compaREST-Windows
193+ name: compaREST binary – Windows
157 path: compaREST
194 path: compaREST
159− - name: Upload Windows compaREST bundle
196+ - name: Upload compaREST binary – Windows to release
160− uses: actions/upload-artifact@v2
197+ if: github.event_name == 'release'
198+ uses: svenstaro/upload-release-action@2.2.1
200+ repo_token: ${{ secrets.GITHUB_TOKEN }}
162− name: compaREST-Windows
202+ asset_name: compaREST binary – Windows
163− path: compaREST
203+ tag: ${{ github.ref }}
165 - name: Cache Nix post
205 - name: Cache Nix post
166 uses: ./.github/actions/nix_cache_post
206 uses: ./.github/actions/nix_cache_post