Skip to content

Commit

Permalink
kwa(build): Introduce COMMIT file for building KWA (#2014)
Browse files Browse the repository at this point in the history
Introduce COMMIT file that contains the commit where Katib needs to
checkout inside Kubeflow's common code in order to be built. This file
was integrated in the following places as well, thus a developer may
only update one file each time we need to checkout to a newer commit.
 - Dockerfile
 - GH actions
 - README.md

Signed-off-by: Orfeas Kourkakis <[email protected]>

Signed-off-by: Orfeas Kourkakis <[email protected]>
  • Loading branch information
orfeas-k authored Nov 16, 2022
1 parent c50e1d3 commit 24c970b
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/test-node.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,10 @@ jobs:

- name: Fetch Kubeflow and install common code dependencies
run: |
COMMIT=$(cat pkg/new-ui/v1beta1/frontend/COMMIT)
cd /tmp && git clone https://github.com/kubeflow/kubeflow.git
cd kubeflow
git checkout c4ca7a9
git checkout $COMMIT
cd components/crud-web-apps/common/frontend/kubeflow-common-lib
npm i
npm run build
Expand Down
4 changes: 3 additions & 1 deletion cmd/new-ui/v1beta1/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,11 @@ FROM ubuntu AS fetch-kubeflow-kubeflow
RUN apt-get update && apt-get install git -y

WORKDIR /kf
COPY ./pkg/new-ui/v1beta1/frontend/COMMIT ./
RUN git clone https://github.com/kubeflow/kubeflow.git && \
COMMIT=$(cat ./COMMIT) && \
cd kubeflow && \
git checkout c4ca7a9
git checkout $COMMIT

# --- Build the frontend kubeflow library ---
FROM node:12 AS frontend-kubeflow-lib
Expand Down
5 changes: 3 additions & 2 deletions pkg/new-ui/v1beta1/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,10 @@ In order to build the UI locally, and expose it with a webpack dev server you wi
You can build the common library with:

```bash
cd /tmp && git clone https://github.com/kubeflow/kubeflow.git \
COMMIT=$(cat ./frontend/COMMIT) \
&& cd /tmp && git clone https://github.com/kubeflow/kubeflow.git \
&& cd kubeflow \
&& git checkout c4ca7a9 \
&& git checkout $COMMIT \
&& cd components/crud-web-apps/common/frontend/kubeflow-common-lib

# build the common library module
Expand Down
1 change: 1 addition & 0 deletions pkg/new-ui/v1beta1/frontend/COMMIT
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
c4ca7a9

0 comments on commit 24c970b

Please sign in to comment.