Skip to content

Commit

Permalink
Merge pull request #861 from rstudio/fix-waml-setuptools
Browse files Browse the repository at this point in the history
Fix Workbench for Azure ML build
  • Loading branch information
bschwedler authored Oct 29, 2024
2 parents 6d179dc + 8030892 commit 4fd9cb3
Show file tree
Hide file tree
Showing 6 changed files with 52 additions and 7 deletions.
43 changes: 42 additions & 1 deletion .github/workflows/build-bake.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
- main
- dev
pull_request:

name: Release - Build, Test, and Push
jobs:
setup:
Expand Down Expand Up @@ -374,3 +374,44 @@ jobs:
snyk-org: ${{ secrets.SNYK_ORG }}
snyk-token: '${{ secrets.SNYK_TOKEN }}'

workbench-for-microsoft-azure-ml:
needs: [setup]
name: Workbench for Microsoft Azure ML
runs-on: ubuntu-latest-8x

concurrency:
group: bake-waml-${{ github.ref }}
cancel-in-progress: true

env:
target: workbench-for-microsoft-azure-ml
GIT_SHA: ${{ needs.setup.outputs.GIT_SHA }}

steps:
- name: Checkout
if: github.event_name == 'schedule'
uses: actions/checkout@v4
with:
ref: 'main'

- name: Checkout
if: github.event_name != 'schedule'
uses: actions/checkout@v4

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
id: setup-buildx
with:
buildkitd-config: ./share/buildkitd.toml

- name: Build, Test, and Push
uses: ./.github/actions/bake-test-push
with:
target: ${{ env.target }}
push-image: ${{ github.ref == 'refs/heads/main' || github.event_name == 'schedule' }}
ghcr-token: ${{ secrets.GITHUB_TOKEN }}
dockerhub-username: ${{ secrets.DOCKER_HUB_USERNAME }}
dockerhub-token: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
gcp-json: '${{ secrets.GCP_ARTIFACT_REGISTRY_JSON }}'
snyk-org: ${{ secrets.SNYK_ORG }}
snyk-token: '${{ secrets.SNYK_TOKEN }}'
6 changes: 3 additions & 3 deletions .github/workflows/build-manual.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -126,15 +126,15 @@ jobs:
else
VERSION="${{ inputs.version }}"
fi
# Set the appropriate env var
suffix="_VERSION"
if [[ "${{ inputs.type }}" == "preview" ]]; then
suffix="_PREVIEW_VERSION"
elif [[ "${{ inputs.type }}" == "daily" ]]; then
suffix="_DAILY_VERSION"
fi
product="${{ inputs.product }}"
if [[ "$product" == "connect" ]] || [[ "$product" == "connect-content-init" ]] || [[ "$product" == "content-images" ]]; then
product="CONNECT"
Expand All @@ -143,7 +143,7 @@ jobs:
else
product="WORKBENCH"
fi
echo "Setting $product$suffix=$VERSION"
echo "$product$suffix=$VERSION" >> $GITHUB_ENV
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/update-readme.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ jobs:
- {prefix: '', repository: 'content-pro', readme_path: './content/pro/README.md'}
- {prefix: 'rstudio-', repository: 'package-manager', readme_path: './package-manager/README.md'}
- {prefix: '', repository: 'r-session-complete', readme_path: './r-session-complete/README.md'}
- {prefix: 'rstudio-', repository: 'workbench-for-microsoft-azure-ml', readme_path: './workbench-for-microsoft-azure-ml/README.md'}

steps:
- name: Check Out Repo
Expand Down
3 changes: 2 additions & 1 deletion docker-bake.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ function get_tags {
variable BASE_BUILD_MATRIX {
default = {
builds = [
{os = "ubuntu2204", r_primary = "4.4.1", r_alternate = "4.3.3", py_primary = "3.11.10", py_alternate = "3.10.15"},
{os = "ubuntu2204", r_primary = "4.4.0", r_alternate = "4.3.3", py_primary = "3.12.1", py_alternate = "3.11.7"},
{os = "ubuntu2204", r_primary = "4.4.1", r_alternate = "4.3.3", py_primary = "3.12.6", py_alternate = "3.11.10"},
]
Expand Down Expand Up @@ -191,7 +192,7 @@ variable WORKBENCH_GOOGLE_CLOUD_WORKSTATION_BUILD_MATRIX {
variable WORKBENCH_MICROSOFT_AZURE_ML_BUILD_MATRIX {
default = {
builds = [
{os = "ubuntu2204", r_primary = "4.4.1", r_alternate = "4.3.3", py_primary = "3.12.6", py_alternate = "3.11.10"},
{os = "ubuntu2204", r_primary = "4.4.1", r_alternate = "4.3.3", py_primary = "3.11.10", py_alternate = "3.10.15"},
]
}
}
Expand Down
4 changes: 3 additions & 1 deletion workbench-for-microsoft-azure-ml/Dockerfile.ubuntu2204
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,10 @@ RUN /opt/python/"${PYTHON_VERSION_JUPYTER}"/bin/python -m venv /opt/python/jupyt

### Install basic data science packages for Python and R ###
COPY deps/* /
RUN /opt/python/${PYTHON_VERSION}/bin/python3 -m pip install -r /tmp/py_packages.txt \
RUN /opt/python/${PYTHON_VERSION}/bin/python3 -m pip install -U pip setuptools wheel \
&& /opt/python/${PYTHON_VERSION}/bin/python3 -m pip install -r /tmp/py_packages.txt \
&& /opt/python/${PYTHON_VERSION}/bin/python3 -m pip cache purge \
&& /opt/python/${PYTHON_VERSION_ALT}/bin/python3 -m pip install -U pip setuptools wheel \
&& /opt/python/${PYTHON_VERSION_ALT}/bin/python3 -m pip install -r /tmp/py_packages.txt \
&& /opt/python/${PYTHON_VERSION_ALT}/bin/python3 -m pip cache purge \
&& rm /tmp/py_packages.txt
Expand Down
2 changes: 1 addition & 1 deletion workbench-for-microsoft-azure-ml/deps/py_packages.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
azureml
azureml-sdk
azureml-core
azureml-dataset-runtime
azure-ai-ml
Expand Down

0 comments on commit 4fd9cb3

Please sign in to comment.