Skip to content

Commit 6babac8

Browse files
committed
Create opendatahub builders for fabric8 from crds files
0 parents  commit 6babac8

File tree

5 files changed

+1021
-0
lines changed

5 files changed

+1021
-0
lines changed

.github/workflows/build.yaml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Build
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
pull_request:
7+
branches: [ main ]
8+
9+
jobs:
10+
build:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v3
14+
15+
- uses: actions/setup-java@v3
16+
with:
17+
distribution: 'temurin'
18+
java-version: '17'
19+
20+
- name: Cache m2 repo
21+
uses: actions/cache@v3
22+
with:
23+
path: ~/.m2/repository
24+
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
25+
restore-keys: |
26+
${{ runner.os }}-maven-
27+
28+
- name: Validate with Maven
29+
env:
30+
MAVEN_OPTS: "-Xmx6144m"
31+
GITHUB_TOKEN: ${{ secrets.TOKEN }}
32+
run: mvn --batch-mode deploy

.gitignore

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
target/
2+
!.mvn/wrapper/maven-wrapper.jar
3+
!**/src/main/**/target/
4+
!**/src/test/**/target/
5+
6+
### IntelliJ IDEA ###
7+
.idea
8+
9+
### Eclipse ###
10+
.apt_generated
11+
.classpath
12+
.factorypath
13+
.project
14+
.settings
15+
.springBeans
16+
.sts4-cache
17+
18+
### NetBeans ###
19+
/nbproject/private/
20+
/nbbuild/
21+
/dist/
22+
/nbdist/
23+
/.nb-gradle/
24+
build/
25+
!**/src/main/**/build/
26+
!**/src/test/**/build/
27+
28+
### VS Code ###
29+
.vscode/
30+
31+
### Mac OS ###
32+
.DS_Store

pom.xml

Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<project xmlns="http://maven.apache.org/POM/4.0.0"
3+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
5+
<modelVersion>4.0.0</modelVersion>
6+
7+
<groupId>io.odh</groupId>
8+
<artifactId>opendatahub-crds</artifactId>
9+
<version>1.0-SNAPSHOT</version>
10+
11+
<properties>
12+
<maven.compiler.source>17</maven.compiler.source>
13+
<maven.compiler.target>17</maven.compiler.target>
14+
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
15+
<fabric8.version>6.9.2</fabric8.version>
16+
<sundrio.version>0.101.3</sundrio.version>
17+
<lobbok.version>1.18.30</lobbok.version>
18+
<maven.compiler.version>3.11.0</maven.compiler.version>
19+
</properties>
20+
21+
<dependencies>
22+
<dependency>
23+
<groupId>io.fabric8</groupId>
24+
<artifactId>openshift-client</artifactId>
25+
<version>${fabric8.version}</version>
26+
</dependency>
27+
<dependency>
28+
<groupId>io.fabric8</groupId>
29+
<artifactId>kubernetes-model</artifactId>
30+
<version>${fabric8.version}</version>
31+
</dependency>
32+
<dependency>
33+
<groupId>io.fabric8</groupId>
34+
<artifactId>generator-annotations</artifactId>
35+
<version>${fabric8.version}</version>
36+
</dependency>
37+
<dependency>
38+
<groupId>io.fabric8</groupId>
39+
<artifactId>kubernetes-server-mock</artifactId>
40+
<version>${fabric8.version}</version>
41+
<scope>test</scope>
42+
</dependency>
43+
<dependency>
44+
<groupId>io.sundr</groupId>
45+
<artifactId>builder-annotations</artifactId>
46+
<version>${sundrio.version}</version>
47+
<scope>provided</scope>
48+
</dependency>
49+
<dependency>
50+
<groupId>org.projectlombok</groupId>
51+
<artifactId>lombok</artifactId>
52+
<version>${lobbok.version}</version>
53+
<scope>provided</scope>
54+
</dependency>
55+
</dependencies>
56+
57+
<build>
58+
<plugins>
59+
<plugin>
60+
<groupId>io.fabric8</groupId>
61+
<artifactId>java-generator-maven-plugin</artifactId>
62+
<version>${fabric8.version}</version>
63+
<executions>
64+
<execution>
65+
<phase>generate-sources</phase>
66+
<goals>
67+
<goal>generate</goal>
68+
</goals>
69+
</execution>
70+
</executions>
71+
<configuration>
72+
<!-- Workaround for: https://github.com/fabric8io/kubernetes-client/issues/5580 -->
73+
<source>src/main/resources/crds/odh-manifests-data-science-pipelines-operator-crd.yaml</source>
74+
<urls>
75+
https://raw.githubusercontent.com/ExcelentProject/sokar/main/open-data-hub/install/crds.yaml,
76+
https://raw.githubusercontent.com/ExcelentProject/sokar/main/open-data-hub/client/odh-manifests-codeflare-crd.yaml,
77+
https://raw.githubusercontent.com/ExcelentProject/sokar/main/open-data-hub/client/odh-manifests-dashboard-crd.yaml,
78+
<!-- https://raw.githubusercontent.com/ExcelentProject/sokar/main/open-data-hub/client/odh-manifests-data-science-pipelines-operator-crd.yaml, -->
79+
https://raw.githubusercontent.com/ExcelentProject/sokar/main/open-data-hub/client/odh-manifests-kserve-crd.yaml,
80+
https://raw.githubusercontent.com/ExcelentProject/sokar/main/open-data-hub/client/odh-manifests-model-mesh-crd.yaml,
81+
https://raw.githubusercontent.com/ExcelentProject/sokar/main/open-data-hub/client/odh-manifests-model-mesh-overlays-odh-crd.yaml,
82+
https://raw.githubusercontent.com/ExcelentProject/sokar/main/open-data-hub/client/odh-manifests-odh-model-controller-crd.yaml,
83+
https://raw.githubusercontent.com/ExcelentProject/sokar/main/open-data-hub/client/odh-manifests-odh-notebook-controller-kf-notebook-controller-crd.yaml,
84+
https://raw.githubusercontent.com/ExcelentProject/sokar/main/open-data-hub/client/odh-manifests-ray-crd.yaml,
85+
https://raw.githubusercontent.com/ExcelentProject/sokar/main/open-data-hub/client/odh-manifests-trustyai-service-operator-crd.yaml
86+
</urls>
87+
<extraAnnotations>true</extraAnnotations>
88+
<alwaysPreserveUnknown>true</alwaysPreserveUnknown>
89+
</configuration>
90+
</plugin>
91+
</plugins>
92+
</build>
93+
94+
</project>

src/main/java/io/odh/Dummy.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
package io.odh;
2+
3+
public class Dummy {
4+
}

0 commit comments

Comments
 (0)