diff --git a/.github/workflows/deploy-to-staging.yaml b/.github/workflows/deploy-to-staging.yaml new file mode 100644 index 000000000..275cfcc46 --- /dev/null +++ b/.github/workflows/deploy-to-staging.yaml @@ -0,0 +1,59 @@ +name: Deploy images to staging hubs +# use echo ${VAR##*: } to get the value of a variable that is a string with a colon in it +on: + workflow_dispatch: + push: + branches: + - staging + +jobs: + deploy: + runs-on: ubuntu-latest + steps: + - name: Get PR labels + id: pr-labels + uses: irby/get-labels-on-push@v1.0.1 + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + + - name: Checkout + uses: actions/checkout@v4 + + - name: Setup python + uses: actions/setup-python@v5 + with: + python-version: '3.11' + + - name: Check out the image repo + uses: actions/checkout@v4 + with: + fetch-depth: 0 # OR "2" -> To retrieve the preceding commit. + + - name: print out labels just for testing + run: echo "${{ steps.pr-labels.outputs.labels }}" + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -r requirements.txt + pip install --force-reinstall git+https://github.com/shaneknapp/hubploy.git@major-refactor + hubploy --help + hubploy deploy --help + + - name: Auth to gcloud + uses: google-github-actions/auth@v2 + with: + credentials_json: ${{ secrets.GCP_SA_KEY }} + project_id: ${{ secrets.GCP_PROJECT_ID }} + + - name: Install Google Cloud SDK + uses: google-github-actions/setup-gcloud@v2 + + - name: gcloud info + run: gcloud info + + - name: Install SOPS + run: | + mkdir -p ${HOME}/repo/bin + curl -sSL https://github.com/mozilla/sops/releases/download/v3.7.0/sops-v3.7.0.linux -o ${HOME}/repo/bin/sops + chmod 755 ${HOME}/repo/bin/sops diff --git a/deployments/logodev/hubploy.yaml b/deployments/logodev/hubploy.yaml index 7760f94a1..fd2b36d2a 100644 --- a/deployments/logodev/hubploy.yaml +++ b/deployments/logodev/hubploy.yaml @@ -1,15 +1,7 @@ images: images: # temporary update - - name: us-central1-docker.pkg.dev/ucb-datahub-2018/user-images/logodev-user-image:a02e39fbaedb - path: image/ - repo2docker: - base_image: docker.io/library/buildpack-deps:jammy - registry: - provider: gcloud - gcloud: - project: ucb-datahub-2018 - service_key: gcr-key.json + - name: us-central1-docker.pkg.dev/ucb-datahub-2018/user-images/logodev-user-image:829f9eaececd cluster: provider: gcloud diff --git a/deployments/logodev/image/environment.yml b/deployments/logodev/image/environment.yml index 386806bea..c4de2ee40 100644 --- a/deployments/logodev/image/environment.yml +++ b/deployments/logodev/image/environment.yml @@ -51,7 +51,7 @@ dependencies: - ipywidgets==8.0.7 # disable until fixed (probably this: https://github.com/jupyterlab/jupyter-collaboration/issues/162) # - jupyter_collaboration==1.0.1 - - jupyterhub==4.1.5 + - jupyterhub==4.1.6 - nbconvert[webpdf] # - pyppeteer==2.0.0 - pytest-notebook==0.8.1 diff --git a/deployments/logodev/image/infra-requirements.txt b/deployments/logodev/image/infra-requirements.txt index b01c9d80d..0fb0bd930 100644 --- a/deployments/logodev/image/infra-requirements.txt +++ b/deployments/logodev/image/infra-requirements.txt @@ -13,7 +13,7 @@ jupyterlab==4.0.11 nbgitpuller==1.2.1 jupyter-resource-usage==1.0.1 # Matches version in images/hub/Dockerfile -jupyterhub==4.1.5 +jupyterhub==4.1.6 appmode==0.8.0 ipywidgets==8.0.7 jupyter-tree-download==1.0.1