How to package multi maven modules - IT

196 views
Skip to first unread message

cmou...@redhat.com

unread,
Feb 24, 2017, 1:18:03 PM2/24/17
to fabric8
Hi,

I would like to design a multi modules maven project where the module A and module B contains each a Kubernetes/Openshift application.
the Integration tests will be designed under an IT module

ribbon
  module-a
  module-b
  IT

IT module is packaged as a jar and the fabric8 maven plugin contains the dependencies toward module-a and module-b

Unfortunately, when I issue mvn fabric8:resource within module it, it generates this error 

[ERROR] Failed to execute goal io.fabric8:fabric8-maven-plugin:3.1.92:apply (apply) on project it: Failed to create DeploymentConfig from openshift.yml. io.fabric8.kubernetes.client.KubernetesClientException: Failure executing: POST at: https://192.168.64.25:8443/oapi/v1/namespaces/test/deploymentconfigs. Message: DeploymentConfig "it" is invalid: spec.template.spec.containers: Required value. Received status: Status(apiVersion=v1, code=422, details=StatusDetails(causes=[StatusCause(field=spec.template.spec.containers, message=Required value, reason=FieldValueRequired, additionalProperties={})], group=null, kind=DeploymentConfig, name=it, retryAfterSeconds=null, additionalProperties={}), kind=Status, message=DeploymentConfig "it" is invalid: spec.template.spec.containers

As module it doesn't include a kubernetes/openshift application, how can I say to fabric8 to just package module-a & module-b and not IT ?

Regards,

Charles

cmou...@redhat.com

unread,
Feb 24, 2017, 1:22:36 PM2/24/17
to fabric8
Is the trick to add within the configuration section of the f-m-p this parameter

<configuration>
 
<skip>${fabric8.skip}</skip>
 
<enricher>
   
<excludes>
     
<exclude>fmp-controller</exclude>
   
</excludes>
 
</enricher>
</configuration>

James Strachan

unread,
Feb 25, 2017, 4:09:12 AM2/25/17
to Charles Moulliard, fabric8
yeah. There's a large multi-module repository here you can noodle

along with packaging modules to combine multiple manifests together into different packages

--
You received this message because you are subscribed to the Google Groups "fabric8" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fabric8+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
James
-------
Red Hat

Twitter: @jstrachan
Email: james.s...@gmail.com
Blog: https://medium.com/@jstrachan/

open source development platform

open source event based lambda programming
Reply all
Reply to author
Forward
0 new messages