• 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
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

Maven deploy dependencies using sudo account on Linux/Unix

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I am relatively new to Maven and Linux as well. I was trying to set up a maven repository for all the dependencies for the java projects we have and so that the entire can use same version of the dependencies and we will just have share the pom.xml (on svn).

The repository needs to be created on a nfs mount drive on a Linux box (Server#1) at ~/maven/repository

To access Server#1 we use our AD user and password and then su to a user appuser. Though this appuser does not have a password and it asks for the sudo password for the AD user and each AD user is added to sudoers file.
All our build processes need to be run using the appuser. At the moment we are trying to deploy the dependencies and the deploy goal asks for password which scp(ing) to the Server#1.
Is there a way we can by pass this? We have already tried creating rsa keys for server and the client machine though of no use. Here is how I have created the server node in the settings.xml file



Please suggest how can this be done in case we want to continue using same security modes of having users login to linux machine using the AD user/password and su to an account with no password.

Thanks,
Rahul
settingsxml.JPG
[Thumbnail for settingsxml.JPG]
 
Rancher
Posts: 989
9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Use artifactory or nexus to share dependencies.
Use a parent pom to fix the versions.
Use jenkins/hudson to do the deploys.

So, all the developers need to do is write codes, test it, and commit it. The build tool can then take care of the deployments using one build tool user account.
 
Rahul V Dixit
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks E Armitage.

Currently we do not have approval for installing any file server like artifactory or nexus and getting that approved will take a long time due to involved stakeholders and the security policies of the organization.

Is there a way we can manage this on existing linux host till the time we get any of the above approved for use.

Thanks,
Rahul
 
author
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Without the tools that Armitage listed all you are left with is file sharing which will be a complete disaster if you have more than 2 developers (and even with only two it might still be a disaster). Don't spent a lot of time trying to come up with a solution that doesn't work, but rather get your manager to push the approvals through ASAP.

By the way, until the approvals go through, do you have a spare machine anywhere, or even a VM? You can always install the tools there until the official machines are approved.
 
Rahul V Dixit
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Peter, I will do it that way. I do have a spare VM with me where I can install those for the moment till approvals go through. Just wanted to confirm if those are the ways to do things so that I can convince my manager about it.
 
The moustache of a titan! The ad of a flea:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic