简体   繁体   中英

maven build multiple rpms basing on multimodule project

I'm trying to set up maven to build my project in the specific way. I have the following structure:

  • pom.xml
    • module1
      • pom.xml
    • module2
      • pom.xml
      • module2.1
        • pom.xml
      • module2.2
        • pom.xml
      • module2.3
        • pom.xml

I actually want to build separate rpms based on module1, module2.2 and module2.3 and want all these rpms be included into root one. Could, please, anybody help me with that if there is any ways to do this using maven and it's plugin only. Also I want this to be done via profiles, if it's possible. All my tryings led me to nothing.

Thanks in advance!

It looks like you need the maven-assembly-plugin . You should use it and define <moduleSets/> in your assembly descriptor.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM