• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

zipping the properties files and pushing in Nexus repository through maven

 
Ranch Hand
Posts: 38
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i have to zip the property files( property file are not part of war they are maintained externally in folder) .These property file contains database information for all env. I  want to zip then and upload in nexus repository.please let me know how we can do it in maven
 
Saloon Keeper
Posts: 27763
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I would create a Maven JAR project and make the properties files be the sole source resources in it (src/main/resources). That would create a "ZIP" file, since JAR is simply ZIP plus metadata in the META-INF directory.

You can then use Maven to build a product and push that product to Nexus.

How you get it from Nexus to the target server is something I'm less clear about. My own strategy for stuff like that is usually to build an OS install package (RPM, deb, msi or whatever) and hand it off to whoever's deploying the app. Which might be a person or a software provisioning agent such as Puppet or Ansible. You could just manually install the ZIP also, but I like to be kind to my operations team,

Alternatively you could let Jenkins or a similar build control/continuous integration system do the job. Depends on how your shop is organized.
reply
    Bookmark Topic Watch Topic
  • New Topic