Skip to content

Commit

Permalink
Merge pull request #39 from ACCESS-NRI/34-add-mule-to-release-payu
Browse files Browse the repository at this point in the history
Add mule,xarray to release payu environment
  • Loading branch information
jo-basevi authored Aug 20, 2024
2 parents ebb09f0 + cc6083b commit 3ca840f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
11 changes: 7 additions & 4 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
conda-lock lock --file env.yml --platform linux-64 --micromamba --lockfile ${{ steps.payu.outputs.name }}.conda-lock.yml
- name: Upload Artifact
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: ${{ steps.payu.outputs.name }}
if-no-files-found: error
Expand All @@ -74,7 +74,7 @@ jobs:
permissions:
contents: write
steps:
- uses: actions/download-artifact@v3.0.2
- uses: actions/download-artifact@v4
with:
name: ${{ env.NAME }}

Expand All @@ -99,14 +99,17 @@ jobs:
ssh ${{ secrets.USER }}@${{ secrets.HOST }} -i ${{ steps.ssh.outputs.private-key-path }} /bin/bash <<'EOT'
mkdir ${{ env.PAYU_ENVIRONMENT_LOCATION }}
if [ $? -ne 0 ]; then
exit $?
# Replace pre-existing environment
echo "::warning::Removing pre-existing environment at: ${{ env.PAYU_ENVIRONMENT_LOCATION }}"
rm -rf "${{ env.PAYU_ENVIRONMENT_LOCATION }}"
mkdir ${{ env.PAYU_ENVIRONMENT_LOCATION }}
fi
tar -xzf ${{ vars.PACK_LOCATION }}/${{ env.NAME }}.tar.gz -C ${{ env.PAYU_ENVIRONMENT_LOCATION }}
source ${{ env.PAYU_ENVIRONMENT_LOCATION }}/bin/activate
conda-unpack
payu --version
source ${{ env.PAYU_ENVIRONMENT_LOCATION }}/bin/deactivate
ln -s ${{ vars.MODULE_LOCATION }}/.common ${{ vars.MODULE_LOCATION }}/${{ env.VERSION }}
ln -sf ${{ vars.MODULE_LOCATION }}/.common ${{ vars.MODULE_LOCATION }}/${{ env.VERSION }}
EOT
# Release
Expand Down
2 changes: 2 additions & 0 deletions env.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@ dependencies:
- nco
- pytest
- openssh>=8.3
- xarray
- mule

0 comments on commit 3ca840f

Please sign in to comment.