Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add mule,xarray to release payu environment #39

Merged
merged 4 commits into from
Aug 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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