aspose file tools*
The moose likes Ant, Maven and Other Build Tools and the fly likes Maven installation and using in project without Internet conncetion Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "Maven installation and using in project without Internet conncetion " Watch "Maven installation and using in project without Internet conncetion " New topic
Author

Maven installation and using in project without Internet conncetion

Krishna Seetha Raman
Greenhorn

Joined: Jan 27, 2011
Posts: 3

I'm new to maven project. I'm changing an ant project to maven project. To install the 3rd party jar's in maven local repository, I used install command. Its trying to download the resource jar.pom. I don't have download access in my organization so the build failed for installation. After request i got the resource jar and clean jar in my desktop(also i can get other necessary jar). How to make maven to use these jar for the process and how to install the jar in local repository without internet access.

I downloaded the jar and placed in local repository but it couldn't point the path and use those jars.

please let me know what steps i have follow to run maven install and other commands to build the project without internet access.

where should i placed the jar which i have downloaded by external way.

Please guide me for building and deploying the project.

Thanks in advance.

Thanks for the reply. But i have not reached the solution. Because I used the command install-file,mvn install:install-file -Dfile=Logger.jar \ -DgroupId=Log \ -DartifactId=Logger \ -Dversion=1.1 \ -DgeneratePom=true ..... It tries to download http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-compiler-plugin/2.3.2/maven-compiler-plugin-2.3.2.pom.. It will not be allowed by my organisation.. so i downloaded maven compler plugin,clean,install,resource and placed in local repostiory still it fails to install jar..

from which directory we should run install-file command because it prompts for pom file when i used the command from default structure


I've posted the same question in stackoverflow.com
http://stackoverflow.com/questions/6609443/maven-installation-and-using-in-project-without-internet-conncetion.
and in maven forum
http://maven.40175.n5.nabble.com/Maven-installation-and-using-in-project-without-Internet-conncetion-td4564443.html
I couldn't solve the issue with the replies.
I believe this is the right place to post the question.
Please help me out to solve the issue.
Thanks in advance.. Awaiting solution for my issue.
Wouter Oet
Saloon Keeper

Joined: Oct 25, 2008
Posts: 2700

No idea why you posted this question in the Job section but let's try it here.


"Any fool can write code that a computer can understand. Good programmers write code that humans can understand." --- Martin Fowler
Please correct my English.
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16236
    
  21

Welcome to the JavaRanch, Krishna!

There are certain minimum resources required to do any job and your employer is severely handicapping you when they forbid access to the components required to do your work.

It is possible to do Maven builds while in a hermetically-sealed box, but it's going to be slow, awkward uncomfortable, and for your employer - expensive. Doubly-so if they also forbid such amenities as access to the online documentation and support resources - I get a lot of aid from googling for various people's "how-to" blogs. Presumably, you have at least some support, even if it means you had to post your plea from an Internet café. Otherwise you wouldn't be here.

But I digress. You can run Maven without an Internet connection by using the "-o" (offline) command-line switch. I use it because even with a good-quality continuous net connection, the need to do online checks on every build slows down Maven a bit. Once a day I do a full online build just to keep the cache fresh, but a lot of my short-term builds are offline. So you're in good company.

When you install a module into Maven manually, it's a good idea to supply the absolute path location of the component being installed. It doesn't actually matter what directory you're located in when you do that, since the absolute path is independent of your current directory, since it is, after all, absolute.

On the other hand, when you do a maven build, whether online or offline, the simplest way to do that is to have your current working directory be the directory that contains the pom.xml file.


Customer surveys are for companies who didn't pay proper attention to begin with.
 
 
subject: Maven installation and using in project without Internet conncetion