Skip to content

Commit 4bc5a0c

Browse files
committed
Update Katib operator and image
Updates Docker image to include changes from #1450, and updates operator to latest version of operator framework.
1 parent c6c9172 commit 4bc5a0c

27 files changed

+673
-619
lines changed

.github/workflows/test-charmed-katib.yaml

Lines changed: 40 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,25 @@ on:
55
- pull_request
66

77
jobs:
8+
lint:
9+
name: Lint
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- name: Check out code
14+
uses: actions/checkout@v2
15+
16+
- name: Install dependencies
17+
run: |
18+
sudo apt-get install python3-setuptools
19+
sudo pip3 install black flake8
20+
21+
- name: Check black
22+
run: black --check operators
23+
24+
- name: Check flake8
25+
run: cd operators && flake8
26+
827
build:
928
name: Test
1029
runs-on: ubuntu-latest
@@ -25,7 +44,7 @@ jobs:
2544
sudo snap install juju --classic
2645
sudo snap install juju-helpers --classic
2746
sudo snap install juju-wait --classic
28-
sudo apt update
47+
sudo pip3 install charmcraft
2948
3049
- name: Build Docker images
3150
run: |
@@ -47,21 +66,14 @@ jobs:
4766
git clone git://git.launchpad.net/canonical-osm
4867
cp -r canonical-osm/charms/interfaces/juju-relation-mysql mysql
4968
sg microk8s -c 'juju bootstrap microk8s uk8s'
50-
juju add-model katib
69+
juju add-model kubeflow
5170
juju bundle deploy -b bundle-edge.yaml --build
5271
juju wait -wvt 300
5372
5473
- name: Test Katib
5574
run: |
5675
set -eux
57-
kubectl run \
58-
--rm \
59-
-i \
60-
--restart=Never \
61-
--image=ubuntu \
62-
katib-check \
63-
-- \
64-
bash -c "apt update && apt install -y curl && curl -f http://katib-ui.katib.svc.cluster.local:8080/katib/"
76+
kubectl apply -f examples/v1beta1/random-example.yaml
6577
6678
- name: Get pod statuses
6779
run: kubectl get all -A
@@ -71,14 +83,26 @@ jobs:
7183
run: juju status
7284
if: failure()
7385

74-
- name: Get katib-controller logs
75-
run: kubectl logs --tail 100 -nkatib -ljuju-app=katib-controller
86+
- name: Get katib-controller workload logs
87+
run: kubectl logs --tail 100 -nkubeflow -ljuju-app=katib-controller
88+
if: failure()
89+
90+
- name: Get katib-controller operator logs
91+
run: kubectl logs --tail 100 -nkubeflow -ljuju-operator=katib-controller
92+
if: failure()
93+
94+
- name: Get katib-ui workload logs
95+
run: kubectl logs --tail 100 -nkubeflow -ljuju-app=katib-ui
96+
if: failure()
97+
98+
- name: Get katib-ui operator logs
99+
run: kubectl logs --tail 100 -nkubeflow -ljuju-operator=katib-ui
76100
if: failure()
77101

78-
- name: Get katib-ui logs
79-
run: kubectl logs --tail 100 -nkatib -ljuju-app=katib-ui
102+
- name: Get katib-db-manager workload logs
103+
run: kubectl logs --tail 100 -nkubeflow -ljuju-app=katib-db-manager
80104
if: failure()
81105

82-
- name: Get katib-manager logs
83-
run: kubectl logs --tail 100 -nkatib -ljuju-app=katib-manager
106+
- name: Get katib-db-manager operator logs
107+
run: kubectl logs --tail 100 -nkubeflow -ljuju-operator=katib-db-manager
84108
if: failure()

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ __pycache__/
44
.coverage
55
.pytest_cache
66
*.egg-info
7+
build/
8+
*.charm
79

810
# Project specific ignore files
911
*.swp

operators/.flake8

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[flake8]
2+
max-line-length = 100

operators/bundle.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
bundle: kubernetes
22
applications:
3-
katib-controller: { charm: katib-controller, scale: 1, annotations: { gui-x: '0', gui-y: '0' } }
4-
katib-db: { charm: cs:~charmed-osm/mariadb-k8s, scale: 1, annotations: { gui-x: '0', gui-y: '300' }, options: { database: katib } }
5-
katib-db-manager: { charm: katib-db-manager, scale: 1, annotations: { gui-x: '300', gui-y: '0' } }
6-
katib-ui: { charm: katib-ui, scale: 1, annotations: { gui-x: '300', gui-y: '300' } }
3+
katib-controller: { charm: katib-controller, scale: 1 }
4+
katib-db: { charm: cs:~charmed-osm/mariadb-k8s, scale: 1, options: { database: katib } }
5+
katib-db-manager: { charm: katib-db-manager, scale: 1 }
6+
katib-ui: { charm: katib-ui, scale: 1 }
77
relations:
88
- [katib-db-manager, katib-db]

operators/katib-controller/layer.yaml

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

operators/katib-controller/metadata.yaml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,16 @@ description: |
88
hyperparameters of applications written in any language of the users’ choice and natively
99
supports many ML frameworks, such as TensorFlow, MXNet, PyTorch, XGBoost, and others.
1010
tags: [ai, bigdata, katib, kubeflow, machine-learning, hyperparameter]
11-
maintainers: [Kenneth Koski <[email protected]>]
11+
maintainers:
12+
- Dominik Fleischmann <[email protected]>
13+
- Kenneth Koski <[email protected]>
1214
series: [kubernetes]
1315
resources:
1416
oci-image:
1517
type: oci-image
1618
description: Backing OCI image
1719
auto-fetch: true
18-
upstream-source: docker.io/kubeflowkatib/katib-controller:v1beta1-a96ff59
20+
upstream-source: docker.io/kubeflowkatib/katib-controller:v1beta1-c6c9172
1921
provides:
2022
katib-controller:
2123
interface: http

0 commit comments

Comments
 (0)