Skip to content

Commit 3aef0c8

Browse files
authored
Merge branch 'main' into tylertitsworth/weekly-patch
2 parents 36addb5 + 9f1bd60 commit 3aef0c8

File tree

6 files changed

+85
-14
lines changed

6 files changed

+85
-14
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"RHEL_OS": ["9.2"],
3+
"experimental": [true],
4+
"runner_label": ["gaudi2"]
5+
}

enterprise/redhat/openshift-ai/gaudi/docker/Dockerfile.rhel9.2

+1-1
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,6 @@ RUN cd ${APP_ROOT}/ && \
231231
VLLM_TARGET_DEVICE=hpu pip install -e .
232232

233233
WORKDIR ${APP_ROOT}/src
234-
ENV NOTEBOOK_SAMPLE_LINK="https://raw.githubusercontent.com/sharvil10/ai-containers/main/enterprise/redhat/openshift-ai/gaudi/demo/Getting-started.ipynb"
234+
ENV NOTEBOOK_SAMPLES_LINK="https://raw.githubusercontent.com/intel/ai-containers/refs/heads/main/enterprise/redhat/openshift-ai/gaudi/demo/oneapi-sample.ipynb"
235235

236236
ENTRYPOINT ["bash", "-c", "/opt/app-root/builder/run"]

enterprise/redhat/openshift-ai/gaudi/docker/docker-compose.yaml

+12-3
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,10 @@ services:
2727
context: .
2828
target: gaudi-base
2929
dockerfile: Dockerfile.rhel${RHEL_OS:-9.2}
30-
image: gaudi-base:${RHEL_OS:-9.2}-${VERSION:-1.17.0}-${REVISION:-495}
30+
image: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-gaudi-base-${VERSION:-1.17.0}-${REVISION:-495}-rhel-${RHEL_OS:-9.2}
31+
entrypoint: ["/bin/bash", "-c"]
32+
command: >
33+
"hl-smi"
3134
gaudi-pytorch:
3235
build:
3336
args:
@@ -44,7 +47,10 @@ services:
4447
context: .
4548
target: gaudi-pytorch
4649
dockerfile: Dockerfile.rhel${RHEL_OS:-9.2}
47-
image: gaudi-pytorch:${RHEL_OS:-9.2}-${VERSION:-1.17.0}-${REVISION:-495}
50+
image: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-gaudi-pytorch-${VERSION:-1.17.0}-${REVISION:-495}-rhel-${RHEL_OS:-9.2}
51+
entrypoint: ["/bin/bash", "-c"]
52+
command: >
53+
"python -c 'import torch'"
4854
gaudi-notebooks:
4955
build:
5056
args:
@@ -61,4 +67,7 @@ services:
6167
context: .
6268
target: gaudi-notebooks
6369
dockerfile: Dockerfile.rhel${RHEL_OS:-9.2}
64-
image: gaudi-notebooks:${RHEL_OS:-9.2}-${VERSION:-1.17.0}-${REVISION:-495}
70+
image: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-gaudi-notebook-${VERSION:-1.17.0}-${REVISION:-495}-rhel-${RHEL_OS:-9.2}
71+
entrypoint: ["/bin/bash", "-c"]
72+
command: >
73+
"python -m jupyter notebook --version"
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
#!/bin/bash
2+
3+
# Copyright (c) 2024 Intel Corporation
4+
#
5+
# Licensed under the Apache License, Version 2.0 (the "License");
6+
# you may not use this file except in compliance with the License.
7+
# You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
16+
17+
set -e
18+
19+
apt-get -y update
20+
apt-get -y install curl jq
21+
22+
echo 'Testing if server is running'
23+
curl --fail -s -X GET http://localhost:8888/api/status
24+
echo ''
25+
26+
echo 'Test if oneapi-sample was downloaded'
27+
if [[ $(curl --fail -s -X GET http://localhost:8888/api/contents | jq -r '.content[] | select(.name=="oneapi-sample.ipynb")') ]]; then
28+
echo 'oneapi-sample.ipynb was downloaded'
29+
else
30+
echo 'oneapi-sample.ipynb was not downloaded'
31+
fi
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# Copyright (c) 2024 Intel Corporation
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
test-jupyter-server:
16+
img: ${REGISTRY}/${REPO}:b-${GITHUB_RUN_NUMBER:-0}-gaudi-base-${VERSION:-1.17.0}-${REVISION:-495}-rhel-${RHEL_OS:-9.2}
17+
cmd: bash /opt/app-root/notebook-test.sh
18+
serving: True
19+
volumes:
20+
- src: $PWD/enterprise/redhat/openshift-ai/gaudi/docker/tests/notebook-test.sh
21+
dst: /opt/app-root/notebook-test.sh
22+
env:
23+
NOTEBOOK_ARGS: "--ServerApp.token='' --ServerApp.PasswordIdentityProvider.hashed_password=''"
24+
NOTEBOOK_PORT: '8888'
25+
NOTEBOOK_SAMPLES_LINK: 'https://raw.githubusercontent.com/intel/ai-containers/refs/heads/main/enterprise/redhat/openshift-ai/gaudi/demo/oneapi-sample.ipynb'
26+
shm_size: 1g

preset/README.md

+10-10
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ AI Tools Selector Preset Containers provides data scientists and developers with
1818
2. Pull a Preset Container of your choice from the [AI Tools Selector](https://www.intel.com/content/www/us/en/developer/tools/oneapi/ai-tools-selector.html) or from the [table](#preset-containers). The commands below use the `deep-learning` preset as an example.
1919

2020
```bash
21-
docker pull intel/deep-learning:latest-py3.9
21+
docker pull intel/deep-learning:latest-py<version>
2222
```
2323

2424
## Run Preset Container
@@ -40,9 +40,9 @@ This mode allows running the container in an interactive shell. This enables the
4040

4141
```bash
4242
docker run -it --rm \
43-
--shm-size=12G \
43+
-p 8888:8888 --shm-size=12G \
4444
-v ${PWD}:/home/dev/workdir \
45-
intel/deep-learning:latest-py3.9 bash
45+
intel/deep-learning:latest-py<version> bash
4646
```
4747

4848
> [!NOTE]
@@ -64,10 +64,10 @@ docker run -it --rm \
6464
${RENDER_GROUP} \
6565
${VIDEO_GROUP} \
6666
--device=/dev/dri \
67-
--shm-size=12G \
67+
-p 8888:8888 --shm-size=12G \
6868
-v ${PWD}:/home/dev/workdir \
6969
-v /dev/dri/by-path:/dev/dri/by-path \
70-
intel/deep-learning:latest-py3.9 bash
70+
intel/deep-learning:latest-py<version> bash
7171
```
7272

7373
> [!NOTE]
@@ -100,9 +100,9 @@ This mode launches a jupyterlab notebook server. The command below will start th
100100
101101
```bash
102102
docker run -it --rm \
103-
--shm-size=12G \
103+
-p 8888:8888 --shm-size=12G \
104104
-v ${PWD}:/home/dev/workdir \
105-
intel/deep-learning:latest-py3.9
105+
intel/deep-learning:latest-py<version>
106106
```
107107
108108
> [!NOTE]
@@ -124,10 +124,10 @@ docker run -it --rm \
124124
${RENDER_GROUP} \
125125
${VIDEO_GROUP} \
126126
--device=/dev/dri \
127-
--shm-size=12G \
127+
-p 8888:8888 --shm-size=12G \
128128
-v ${PWD}:/home/dev/workdir \
129129
-v /dev/dri/by-path:/dev/dri/by-path \
130-
intel/deep-learning:latest-py3.9
130+
intel/deep-learning:latest-py<version>
131131
```
132132

133133
> [!NOTE]
@@ -146,7 +146,7 @@ docker run -it --rm \
146146
Modify your notebook server command by using the default example below to change the network (port/ip) and security (privilege) settings by appending it to the docker run commands above:
147147

148148
```bash
149-
docker run ... intel/deep-learning:latest-py3.9 \
149+
docker run ... intel/deep-learning:latest-py<version> \
150150
bash -c "jupyter notebook --notebook-dir=~/jupyter \
151151
--port 8888 \
152152
--ip 0.0.0.0 \

0 commit comments

Comments
 (0)