Create datahub PR #5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Create datahub PR | |
on: | |
workflow_run: | |
workflows: ['Build and push container image'] | |
types: [completed] | |
branches: | |
- main | |
jobs: | |
create-pr: | |
runs-on: ubuntu-latest | |
env: | |
HUB: ${{ vars.HUB }} | |
IMAGE: "ucb-datahub-2018/user-images/${HUB}-user-image" | |
steps: | |
- name: Generate the image name | |
run: | | |
IMAGE="ucb-datahub-2018/user-images/${HUB}-user-image" | |
echo "IMAGE=$IMAGE" >> $GITHUB_ENV | |
- name: Test if vars works | |
run: | | |
echo "with vars:" | |
echo ${{ vars.HUB }} | |
echo "no vars:" | |
echo ${HUB} | |
- name: Maximize build space | |
uses: easimon/maximize-build-space@master | |
with: | |
root-reserve-mb: 512 | |
swap-size-mb: 1024 | |
remove-dotnet: 'true' | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Display free space | |
run: | | |
echo "Free space:" | |
df -h | |
- name: Checkout files in repo | |
uses: actions/checkout@v4 | |
with: | |
repository: 'berkeley-dsep-infra/datahub' | |
sparse-checkout: | | |
hub/ | |
deployments/ | |
- name: see if the correct dir has been checked out, and the requirements have been installed | |
run: | | |
ls -la | |
tree | |
# Lets us monitor disks getting full as images get bigger over time | |
- name: Show how much disk space is left | |
run: df -h |