Skip to content

Commit 20ff1e9

Browse files
committed
Use separate konflux-build-driver repository
1 parent c9eeb12 commit 20ff1e9

File tree

21 files changed

+30
-801
lines changed

21 files changed

+30
-801
lines changed

java-components/cli/pom.xml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,6 @@
2424
<groupId>io.github.redhat-appstudio.jvmbuild</groupId>
2525
<artifactId>hacbs-resource-model</artifactId>
2626
</dependency>
27-
28-
<dependency>
29-
<groupId>io.github.redhat-appstudio.jvmbuild</groupId>
30-
<artifactId>driver</artifactId>
31-
</dependency>
32-
3327
<dependency>
3428
<groupId>info.picocli</groupId>
3529
<artifactId>picocli-shell-jline2</artifactId>
@@ -70,6 +64,10 @@
7064
<groupId>com.google.cloud.tools</groupId>
7165
<artifactId>jib-core</artifactId>
7266
</dependency>
67+
<dependency>
68+
<groupId>org.jboss.pnc</groupId>
69+
<artifactId>konflux-build-driver</artifactId>
70+
</dependency>
7371
<dependency>
7472
<groupId>org.jboss.logging</groupId>
7573
<artifactId>commons-logging-jboss-logging</artifactId>
@@ -115,6 +113,7 @@
115113
<artifactId>wiremock</artifactId>
116114
<scope>test</scope>
117115
</dependency>
116+
118117
</dependencies>
119118
<build>
120119
<plugins>

java-components/cli/src/main/java/com/redhat/hacbs/cli/driver/Base.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,6 @@ public abstract class Base {
3434
@CommandLine.Option(names = "--dependencies", description = "Dependencies URL", required = true)
3535
String dependencies;
3636

37-
@CommandLine.Option(names = "-i", description = "Recipe Image", defaultValue = "quay.io/redhat-user-workloads/konflux-jbs-pnc-tenant/jvm-build-service-builder-images/ubi8:latest")
38-
String recipeImage;
39-
4037
@ConfigProperty(name = "access.token")
4138
Optional<String> accessToken;
4239

java-components/cli/src/main/java/com/redhat/hacbs/cli/driver/CancelPipeline.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,11 @@
33
import jakarta.enterprise.context.control.ActivateRequestContext;
44
import jakarta.inject.Inject;
55

6+
import org.jboss.pnc.konfluxbuilddriver.Driver;
7+
import org.jboss.pnc.konfluxbuilddriver.dto.CancelRequest;
68
import org.slf4j.Logger;
79
import org.slf4j.LoggerFactory;
810

9-
import com.redhat.hacbs.driver.Driver;
10-
import com.redhat.hacbs.driver.dto.CancelRequest;
11-
1211
import picocli.CommandLine;
1312

1413
@CommandLine.Command(name = "cancel-pipeline", mixinStandardHelpOptions = true, description = "Creates a pipeline")

java-components/cli/src/main/java/com/redhat/hacbs/cli/driver/CreatePipeline.java

Lines changed: 18 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,12 @@
33
import jakarta.enterprise.context.control.ActivateRequestContext;
44
import jakarta.inject.Inject;
55

6+
import org.jboss.pnc.konfluxbuilddriver.Driver;
7+
import org.jboss.pnc.konfluxbuilddriver.dto.BuildRequest;
8+
import org.jboss.pnc.konfluxbuilddriver.dto.BuildResponse;
69
import org.slf4j.Logger;
710
import org.slf4j.LoggerFactory;
811

9-
import com.redhat.hacbs.driver.Driver;
10-
import com.redhat.hacbs.driver.dto.BuildRequest;
11-
import com.redhat.hacbs.driver.dto.BuildResponse;
12-
1312
import picocli.CommandLine;
1413

1514
@CommandLine.Command(name = "create-pipeline", mixinStandardHelpOptions = true, description = "Creates a pipeline")
@@ -20,18 +19,26 @@ public class CreatePipeline extends Base implements Runnable {
2019
@Inject
2120
Driver driver;
2221

23-
@CommandLine.Option(names = "--quay", description = "Quay repo", defaultValue = "quay.io/redhat-user-workloads-stage/pnc-devel-tenant/pnc-konflux")
24-
String quayRepo;
22+
@CommandLine.Option(names = "-i", description = "Recipe Image", defaultValue = "quay.io/redhat-user-workloads/konflux-jbs-pnc-tenant/jvm-build-service-builder-images/ubi8:latest")
23+
String recipeImage;
2524

26-
@CommandLine.Option(names = "--processor", description = "Request Process Image", defaultValue = "quay.io/redhat-user-workloads/konflux-jbs-pnc-tenant/jvm-build-service/build-request-processor:latest")
27-
String processor;
25+
// Not possible to set Quarkus configuration via CLI due to
26+
// https://github.com/quarkusio/quarkus/issues/19128
27+
// Therefore create an application.properties file in the directory where the CLI is run
28+
// and configure the values there manually.
29+
//
30+
// @CommandLine.Option(names = "--quay", description = "Quay repo", defaultValue = "quay.io/redhat-user-workloads-stage/pnc-devel-tenant/pnc-konflux")
31+
// String quayRepo;
32+
//
33+
// @CommandLine.Option(names = "--processor", description = "Request Process Image", defaultValue = "quay.io/redhat-user-workloads/konflux-jbs-pnc-tenant/jvm-build-service/build-request-processor:latest")
34+
// String processor;
2835

2936
@ActivateRequestContext // https://github.com/quarkusio/quarkus/issues/8758
3037
@Override
3138
public void run() {
32-
driver.setQuayRepo(quayRepo);
33-
driver.setProcessor(processor);
34-
driver.setAccessToken(accessToken.orElse(""));
39+
// driver.setQuayRepo(quayRepo);
40+
// driver.setProcessor(processor);
41+
// driver.setAccessToken(accessToken.orElse(""));
3542

3643
BuildRequest request = BuildRequest.builder()
3744
.namespace(namespace)

java-components/driver/pom.xml

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

0 commit comments

Comments
 (0)