@@ -255,6 +255,24 @@ jobs:
255255 if-no-files-found : error
256256 retention-days : 1
257257
258+ # If the 'linux/amd64' -dist image was just updated for the 'main' branch,
259+ # Then redeploy https://sandbox.dspace.org using that updated image.
260+ - name : Redeploy sandbox.dspace.org (based on main branch)
261+ if : ${{ ! matrix.isPr && matrix.arch == 'linux/amd64' && github.ref_name == github.event.repository.default_branch }}
262+ run : |
263+ curl -X POST $REDEPLOY_SANDBOX_URL
264+ env :
265+ REDEPLOY_SANDBOX_URL : ${{ secrets.REDEPLOY_SANDBOX_URL }}
266+
267+ # If the 'linux/amd64' -dist image was just updated for the maintenance branch,
268+ # Then redeploy https://demo.dspace.org using that updated image.
269+ - name : Redeploy demo.dspace.org (based on maintenace branch)
270+ if : ${{ ! matrix.isPr && matrix.arch == 'linux/amd64' && github.ref_name == 'dspace-7_x' }}
271+ run : |
272+ curl -X POST $REDEPLOY_DEMO_URL
273+ env :
274+ REDEPLOY_DEMO_URL : ${{ secrets.REDEPLOY_DEMO_URL }}
275+
258276 # Merge *-dist digests into a manifest.
259277 # This runs after all Docker builds complete above, and it tells hub.docker.com
260278 # that these builds should be all included in the manifest for this tag.
@@ -300,25 +318,3 @@ jobs:
300318 - name : Inspect image
301319 run : |
302320 docker buildx imagetools inspect ${{ env.REGISTRY_IMAGE }}:${{ steps.meta_dist.outputs.version }}
303-
304- # Deploy latest -dist image to Demo or Sandbox site, based on the branch updated
305- dspace-angular-dist_deploy :
306- if : ${{ github.event_name != 'pull_request' }}
307- runs-on : ubuntu-latest
308- needs :
309- # Requires manifest to be fully updated on DockerHub
310- - dspace-angular-dist_manifest
311- steps :
312- - name : Redeploy sandbox.dspace.org (based on main branch)
313- if : ${{ github.ref_name == github.event.repository.default_branch }}
314- run : |
315- curl -X POST -d '{}' $REDEPLOY_SANDBOX_URL
316- env :
317- REDEPLOY_SANDBOX_URL : ${{ secrets.REDEPLOY_SANDBOX_URL }}
318-
319- - name : Redeploy demo.dspace.org (based on maintenace branch)
320- if : ${{ github.ref_name == 'dspace-7_x' }}
321- run : |
322- curl -X POST -d '{}' $REDEPLOY_DEMO_URL
323- env :
324- REDEPLOY_DEMO_URL : ${{ secrets.REDEPLOY_DEMO_URL }}
0 commit comments