After you have successfully started artifactory service as root you need to go
http://localhost:8081/artifactory OR in our case
http://[serverip]:[serverport]/artifactory
[serverport] : Artifactory comes with an artifactory.war file.When you start artifactory service it deploys it to jetty server which comes with artifactory.So serverport must point to used webserver default port where artifactory.war is deployed. Here in this case it is 8081 for jetty.For tomcat it 8080 as you forecast.
For first-time admin log in
username :admin
password :password
If you can't log in try to reinstall artifactory.May be some files that you dont know and already exists there override default behaviour which is extremely rare case but take my 4 hours.Be sure that files are yours and clean.
Now you successfully log in to web ui of artifactory.You can deploy your jars,versioning it,do some security settings here.It is the easy part to do.
But it is not the end. We want some behaviour from artifactory repository:
We want artifactory to download needed jars for our project on our internal server so each team member can download jars from internal server and don't have to go Maven Repository or other repositories on the internet. If server doesnt find needed jar on itself It (Server!) download jars on itself after maven command executed by one of the team members.
We should do some configuration to get these behaviour.
Showing posts with label linux. Show all posts
Showing posts with label linux. Show all posts
Friday, January 25, 2008
Setting up an internal maven repository with artifactory in Linux server
First of all i assume that you login as a root to linux.It s neccessary to be root for executing service.
./install.sh [arg1] : This is expected to install artifactory as a linux service. [arg1] is the username of the JETTY_USER.Default is jetty.If you want to override (what i do) you can pass it an argument.(like artifactory)
my ARTIFACTORY_HOME is:
/opt/artifactory
and under ARTIFACTORY_HOME there is etc folder.Under etc execute
vi default
It should like this:
************************
#!/bin/sh
export JAVA_HOME=/opt/java/jre1.5.0_14
export JAVA_OPTIONS="-server -Xms400m -Xmx1g"
export ARTIFACTORY_HOME=/opt/artifactory
export JETTY_USER=artifactory
export JETTY_CONSOLE=${ARTIFACTORY_HOME}/logs/consoleout.log
*************************
JAVA_HOME should point to your jre folder.
JETTY_CONSOLE is where you can find log when artifactory start or may be failed to start which means 1.5 days for me.
Because my JETTY_USER is 'artifactory' there must be a user setting in /etc/init.d/artifactory.
This /etc/init.d/artifactory user MUST have read/write access to artifactory folder.So i suggest you to as a begginner in /opt/artifactory folder and simply write
chmod -R 777 *
and give full access to everybody just for beginning.You can easily configure it when you became more familiar to artifactory/linux/maven blah blah issues.
and here we go
we want to start artifactory via:
service artifactory start
If it says what the hell artifactory service is it means you did sth wrong so stop here and go steps above.Look at /opt/artifactory/etc/default file to check settings are correct.
I suggest you to open another session to linux server before executing start artifactory service and go to /opt/artifactory/logs folder
write :
tail -f consoleout.log
to see what is going on there
If it is successfully started you are lucky:) Almost every try i have a problem so be patient.
There are popular known errors:
java.lang.RuntimeException: Failed to read object from stream.
Failed to execute JcrCallback : FileNotFoundException on tmp file
I hope you successfully installed artifactory and now you can configure it.
./install.sh [arg1] : This is expected to install artifactory as a linux service. [arg1] is the username of the JETTY_USER.Default is jetty.If you want to override (what i do) you can pass it an argument.(like artifactory)
my ARTIFACTORY_HOME is:
/opt/artifactory
and under ARTIFACTORY_HOME there is etc folder.Under etc execute
vi default
It should like this:
************************
#!/bin/sh
export JAVA_HOME=/opt/java/jre1.5.0_14
export JAVA_OPTIONS="-server -Xms400m -Xmx1g"
export ARTIFACTORY_HOME=/opt/artifactory
export JETTY_USER=artifactory
export JETTY_CONSOLE=${ARTIFACTORY_HOME}/logs/consoleout.log
*************************
JAVA_HOME should point to your jre folder.
JETTY_CONSOLE is where you can find log when artifactory start or may be failed to start which means 1.5 days for me.
Because my JETTY_USER is 'artifactory' there must be a user setting in /etc/init.d/artifactory.
This /etc/init.d/artifactory user MUST have read/write access to artifactory folder.So i suggest you to as a begginner in /opt/artifactory folder and simply write
chmod -R 777 *
and give full access to everybody just for beginning.You can easily configure it when you became more familiar to artifactory/linux/maven blah blah issues.
and here we go
we want to start artifactory via:
service artifactory start
If it says what the hell artifactory service is it means you did sth wrong so stop here and go steps above.Look at /opt/artifactory/etc/default file to check settings are correct.
I suggest you to open another session to linux server before executing start artifactory service and go to /opt/artifactory/logs folder
write :
tail -f consoleout.log
to see what is going on there
If it is successfully started you are lucky:) Almost every try i have a problem so be patient.
There are popular known errors:
java.lang.RuntimeException: Failed to read object from stream.
Failed to execute JcrCallback : FileNotFoundException on tmp file
I hope you successfully installed artifactory and now you can configure it.
Etiketler:
artifactory,
linux,
maven
Subscribe to:
Posts (Atom)