Skip to content

Commit c637e95

Browse files
committed
Merge branch '2024b' of github.com:opendatahub-io/notebooks into sync-n
2 parents 0a8a0b8 + e7a87da commit c637e95

File tree

81 files changed

+31434
-28658
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

81 files changed

+31434
-28658
lines changed

OWNERS

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
approvers:
22
- atheo89
33
- caponetto
4+
- daniellutz
45
- harshad16
56
- jiridanek
67
- jstourac
@@ -9,6 +10,7 @@ approvers:
910
reviewers:
1011
- atheo89
1112
- caponetto
13+
- daniellutz
1214
- dibryant
1315
- harshad16
1416
- jiridanek

base/ubi9-python-3.11/Pipfile.lock

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ci/check-json.sh

Lines changed: 46 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/bin/bash
1+
#!/usr/bin/env bash
22
#
33
# This script serves to check YAML files in this repository that contain particular
44
# key fields where JSON string is expected. Such JSON strings are extracted and
@@ -10,7 +10,19 @@
1010
# In case of the PR on GitHub, this check is tied to GitHub actions automatically,
1111
# see `.github/workflows` directory.
1212

13-
shopt -s globstar
13+
if ! shopt -s globstar; then
14+
echo "macOS ships bash-3.2 that does not know shopt -s globstar; install newer bash from homebrew"
15+
exit 1
16+
fi
17+
18+
# yq: `brew install yq` or `apt-get install yq`
19+
# json_verify: `brew install yajl` or `apt-get install yajl-tools`
20+
for dep in yq json_verify; do
21+
if ! which -- ${dep} >/dev/null; then
22+
echo "the dependency ${dep} is not installed; install it now"
23+
exit 1
24+
fi
25+
done
1426

1527
function check_json() {
1628
local f="${1}"
@@ -22,15 +34,19 @@ function check_json() {
2234
echo "Checking: '${f}' - for '${string}':"
2335

2436
if grep --quiet --extended-regexp "${string}" "${f}"; then
25-
#if $(grep -e "${string}" "${f}"); then
26-
jsons=$(yq -r ".spec.tags[].annotations.\"${string}\"" "${f}")
27-
28-
while IFS= read -r json; do
29-
echo " ${json}"
30-
echo -n " > "; echo "${json}" | json_verify || ret_code="${?}"
31-
done <<< "${jsons}"
37+
local tmp_dir
38+
tmp_dir=$(mktemp --directory -t check-jsons-in-file-XXXXXXXXXX-)
39+
if ! (cd "${tmp_dir}"; yq --split-exp "\$index" --unwrapScalar ".spec.tags[].annotations.\"${string}\"" "${f}"); then
40+
echo "yq failed to run"
41+
return 1
42+
fi
43+
44+
for json in "${tmp_dir}"/*.yml; do
45+
echo " "; cat "${json}"
46+
echo -n " > "; json_verify < "${json}" || ret_code="${?}"
47+
done
3248
else
33-
echo " Ignoring as this file doesn't contain necessary key field '${string}' for check"
49+
echo " Ignoring as this file doesn't contain necessary key field '${string}' for check"
3450
fi
3551

3652
return "${ret_code}"
@@ -48,20 +64,27 @@ function split_yaml_file() {
4864
return 0
4965
}
5066

51-
ret_code=0
67+
function main() {
68+
local ret_code=0
5269

70+
# Some yaml files can contain more definitions.
71+
# This is a problem for `yq` tool so we need to split these into separate files.
72+
local tmp_dir
73+
tmp_dir=$(mktemp --directory -t check-json-XXXXXXXXXX-)
74+
for f in **/*.yaml; do
75+
echo "Splitting the '${f}' file."
76+
split_yaml_file "${f}" "${tmp_dir}" || ret_code="${?}"
77+
done
5378

54-
# Some yaml files can contain more definitions.
55-
# This is a problem for `yq` tool so we need to split these into separate files.
56-
tmp_dir=$(mktemp --directory --suffix=-check-json)
57-
for f in **/*.yaml; do
58-
echo "Splitting the '${f}' file."
59-
split_yaml_file "${f}" "${tmp_dir}" || ret_code="${?}"
60-
done
79+
for f in "${tmp_dir}"/*; do
80+
check_json "${f}" "opendatahub.io/notebook-software" || ret_code="${?}"
81+
check_json "${f}" "opendatahub.io/notebook-python-dependencies" || ret_code="${?}"
82+
done
6183

62-
for f in "${tmp_dir}"/*; do
63-
check_json "${f}" "opendatahub.io/notebook-software" || ret_code="${?}"
64-
check_json "${f}" "opendatahub.io/notebook-python-dependencies" || ret_code="${?}"
65-
done
84+
exit "${ret_code}"
85+
}
6686

67-
exit "${ret_code}"
87+
# allows sourcing the script into interactive session without executing it
88+
if [[ "${0}" == "${BASH_SOURCE[0]}" ]]; then
89+
main
90+
fi

codeserver/ubi9-python-3.11/Pipfile.lock

Lines changed: 719 additions & 634 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

codeserver/ubi9-python-3.11/run-code-server.sh

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ source ${SCRIPT_DIR}/utils/*.sh
88
run-nginx.sh &
99
/usr/bin/supervisord -c /etc/supervisor/conf.d/supervisord.conf &
1010

11-
# Add .bashrc for custom promt if not present
11+
# Add .bashrc for custom prompt if not present
1212
if [ ! -f "/opt/app-root/src/.bashrc" ]; then
1313
echo 'PS1="\[\033[34;1m\][\$(pwd)]\[\033[0m\]\n\[\033[1;0m\]$ \[\033[0m\]"' > /opt/app-root/src/.bashrc
1414
fi
@@ -42,16 +42,22 @@ create_dir_and_file() {
4242
# Define universal settings
4343
universal_dir="/opt/app-root/src/.local/share/code-server/User/"
4444
user_settings_filepath="${universal_dir}settings.json"
45-
universal_json_settings='{
45+
universal_json_settings='// vscode settings are written in json-with-comments
46+
/* https://code.visualstudio.com/docs/languages/json#_json-with-comments */
47+
{
4648
"python.defaultInterpreterPath": "/opt/app-root/bin/python3",
4749
"telemetry.telemetryLevel": "off",
4850
"telemetry.enableTelemetry": false,
4951
"workbench.enableExperiments": false,
5052
"extensions.autoCheckUpdates": false,
51-
"extensions.autoUpdate": false
53+
"extensions.autoUpdate": false,
54+
55+
// RHOAIENG-14518: Disable the "Do you trust the authors [...]" startup prompt
56+
"security.workspace.trust.enabled": false,
57+
"security.workspace.trust.startupPrompt": "never"
5258
}'
5359

54-
# Define python debuger settings
60+
# Define python debugger settings
5561
vscode_dir="/opt/app-root/src/.vscode/"
5662
settings_filepath="${vscode_dir}settings.json"
5763
launch_filepath="${vscode_dir}launch.json"
@@ -72,7 +78,7 @@ json_settings='{
7278
"python.defaultInterpreterPath": "/opt/app-root/bin/python3"
7379
}'
7480

75-
# Create necessary directories and files for python debuger and universal settings
81+
# Create necessary directories and files for python debugger and universal settings
7682
create_dir_and_file "$universal_dir" "$user_settings_filepath" "$universal_json_settings"
7783
create_dir_and_file "$vscode_dir" "$settings_filepath" "$json_settings"
7884
create_dir_and_file "$vscode_dir" "$launch_filepath" "$json_launch_settings"

codeserver/ubi9-python-3.11/supervisord/supervisord.conf

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
[supervisord]
22
nodaemon=true
3+
logfile=/tmp/supervisord.log
4+
pidfile=/tmp/supervisord.pid
35

46
[program:fcgiwrap]
57
command=/usr/sbin/fcgiwrap -s unix:/var/run/fcgiwrap.socket

codeserver/ubi9-python-3.9/run-code-server.sh

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ source ${SCRIPT_DIR}/utils/*.sh
88
run-nginx.sh &
99
/usr/bin/supervisord -c /etc/supervisor/conf.d/supervisord.conf &
1010

11-
# Add .bashrc for custom promt if not present
11+
# Add .bashrc for custom prompt if not present
1212
if [ ! -f "/opt/app-root/src/.bashrc" ]; then
1313
echo 'PS1="\[\033[34;1m\][\$(pwd)]\[\033[0m\]\n\[\033[1;0m\]$ \[\033[0m\]"' > /opt/app-root/src/.bashrc
1414
fi
@@ -42,16 +42,22 @@ create_dir_and_file() {
4242
# Define universal settings
4343
universal_dir="/opt/app-root/src/.local/share/code-server/User/"
4444
user_settings_filepath="${universal_dir}settings.json"
45-
universal_json_settings='{
45+
universal_json_settings='// vscode settings are written in json-with-comments
46+
/* https://code.visualstudio.com/docs/languages/json#_json-with-comments */
47+
{
4648
"python.defaultInterpreterPath": "/opt/app-root/bin/python3",
4749
"telemetry.telemetryLevel": "off",
4850
"telemetry.enableTelemetry": false,
4951
"workbench.enableExperiments": false,
5052
"extensions.autoCheckUpdates": false,
51-
"extensions.autoUpdate": false
53+
"extensions.autoUpdate": false,
54+
55+
// RHOAIENG-14518: Disable the "Do you trust the authors [...]" startup prompt
56+
"security.workspace.trust.enabled": false,
57+
"security.workspace.trust.startupPrompt": "never"
5258
}'
5359

54-
# Define python debuger settings
60+
# Define python debugger settings
5561
vscode_dir="/opt/app-root/src/.vscode/"
5662
settings_filepath="${vscode_dir}settings.json"
5763
launch_filepath="${vscode_dir}launch.json"
@@ -72,7 +78,7 @@ json_settings='{
7278
"python.defaultInterpreterPath": "/opt/app-root/bin/python3"
7379
}'
7480

75-
# Create necessary directories and files for python debuger and universal settings
81+
# Create necessary directories and files for python debugger and universal settings
7682
create_dir_and_file "$universal_dir" "$user_settings_filepath" "$universal_json_settings"
7783
create_dir_and_file "$vscode_dir" "$settings_filepath" "$json_settings"
7884
create_dir_and_file "$vscode_dir" "$launch_filepath" "$json_launch_settings"

codeserver/ubi9-python-3.9/supervisord/supervisord.conf

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
[supervisord]
22
nodaemon=true
3+
logfile=/tmp/supervisord.log
4+
pidfile=/tmp/supervisord.pid
35

46
[program:fcgiwrap]
57
command=/usr/sbin/fcgiwrap -s unix:/var/run/fcgiwrap.socket

cuda/ubi9-python-3.11/cuda.repo-arm64

Lines changed: 0 additions & 6 deletions
This file was deleted.

intel/runtimes/ml/ubi9-python-3.11/Pipfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ plotly = "~=5.16.1"
1919
scipy = "~=1.11.2"
2020
scikit-learn = "~=1.3.1"
2121
skl2onnx = "~=1.15.0"
22-
codeflare-sdk = "~=0.22.0"
22+
codeflare-sdk = "~=0.23.1"
2323
# DB connectors
2424
pymongo = "~=4.5.0"
2525
psycopg = "~=3.1.10"

0 commit comments

Comments
 (0)