Skip to content

Commit

Permalink
Fix #73: Ported JIB Support into Eclipse JKube from FMP
Browse files Browse the repository at this point in the history
+ Added a new module `jkube-kit/build/service/jib`
+ Introduced a new `BuildService` for jib : `JibBuildService`
+ Added documentation related to JIB integration
+ Added a simple Spring Boot Quickstart for JIB support demonstration.
  • Loading branch information
rohanKanojia committed Jun 26, 2020
1 parent 4edf23e commit cb50c69
Show file tree
Hide file tree
Showing 42 changed files with 1,502 additions and 53 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ Usage:
* Fix #192: Removed `@Deprecated` fields from ClusterAccess
* Fix #190: Removed `@Deprecated` fields from AssemblyConfiguration
* Fix #189: Removed `@Deprecated` fields from BuildConfiguration
* Fix #73: Jib Support, Port of fabric8io/fabric8-maven-plugin#1766
* Fix #195: Added MigrateMojo for migrating projects from FMP to JKube

### 1.0.0-alpha-4 (2020-06-08)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ public AuthConfigFactory(KitLogger log) {
* @param settings the global Maven settings object
* @param user user to check for
* @param registry registry to use, might be null in which case a default registry is checked,
* @param passwordDecryptionMethod a functional interface to customize how password should be decoded
* @return the authentication configuration or <code>null</code> if none could be found
*
* @throws IOException mojo failure exception
Expand Down Expand Up @@ -177,9 +178,11 @@ private AuthConfig extendedAuthentication(AuthConfig standardAuthConfig, String
* @param settings the global Maven settings object
* @param user user to check for
* @param registry registry to use, might be null in which case a default registry is checked,
* @param passwordDecryptionMethod a function to customize how password should be decoded
* @param log Kit logger
* @return the authentication configuration or <code>null</code> if none could be found
*
* @throws Exception any exception in case of fetching authConfig
* @throws IOException any exception in case of fetching authConfig
*/
public static AuthConfig createStandardAuthConfig(boolean isPush, Map authConfigMap, List<RegistryServerConfiguration> settings, String user, String registry, UnaryOperator<String> passwordDecryptionMethod, KitLogger log)
throws IOException {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,8 @@
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.NoArgsConstructor;
import org.eclipse.jkube.kit.build.service.docker.helper.DeepCopy;

import java.io.Serializable;
import java.lang.String;
import java.util.Map;

/**
Expand All @@ -30,6 +28,7 @@
* @author Tom Burton
* @version Dec 15, 2016
*/
@SuppressWarnings("JavaDoc")
@Builder
@AllArgsConstructor
@NoArgsConstructor
Expand All @@ -41,21 +40,29 @@ public class VolumeConfiguration implements Serializable {

/**
* Volume Name
* @param name name of volume configuration
* @return name of specified volume configuration
*/
private String name;

/**
* Volume driver for mounting the volume
* @param driver volume driver
* @return string indicating volume driver
*/
private String driver;

/**
* Driver specific options
* @param opts driver specific options
* @return map containing driver specific options
*/
private Map<String, String> opts;

/**
* Volume labels
* @param labels volume labels
* @return map containing volume labels
*/
private Map<String, String> labels;

Expand Down
60 changes: 60 additions & 0 deletions jkube-kit/build/service/jib/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2019 Red Hat, Inc.
This program and the accompanying materials are made
available under the terms of the Eclipse Public License 2.0
which is available at:
https://www.eclipse.org/legal/epl-2.0/
SPDX-License-Identifier: EPL-2.0
Contributors:
Red Hat, Inc. - initial API and implementation
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.eclipse.jkube</groupId>
<artifactId>jkube-kit-parent</artifactId>
<version>1.0.0-SNAPSHOT</version>
<relativePath>../../../parent/pom.xml</relativePath>
</parent>

<artifactId>jkube-kit-build-service-jib</artifactId>

<name>JKube Kit :: Build :: Service :: JIB</name>

<dependencies>
<dependency>
<groupId>org.eclipse.jkube</groupId>
<artifactId>jkube-kit-build-api</artifactId>
</dependency>

<dependency>
<groupId>com.google.cloud.tools</groupId>
<artifactId>jib-core</artifactId>
</dependency>

<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-text</artifactId>
</dependency>
<dependency>
<groupId>org.jmockit</groupId>
<artifactId>jmockit</artifactId>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
</dependency>
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-all</artifactId>
</dependency>

</dependencies>
</project>
Loading

0 comments on commit cb50c69

Please sign in to comment.