Home

HOWTO: Change the default port from 8080

You are here

19 posts / 0 new
Last post
HOWTO: Change the default port from 8080

- Ensure your Tomcat instance is looking on our extensions classpath. See http://wiki.alfresco.com/wiki/Install_Tomcat6 for details
- Get share-config-custom.xml.sample from SVN: http://svn.alfresco.com/repos/alfresco-open-mirror/alfresco/HEAD/root/projects/slingshot/config/alfresco/web-extension/
- Copy this file to tomcat/shared/classes/alfresco/web-extension (create the folders if they're not there) and rename it to remove the .sample extension
- Edit this file (notepad will do, or any other text editor).
- You don't need most of the other config, just the section at the bottom... something like this:

<alfresco-config>
 
<config evaluator="string-compare" condition="Remote">
<remote>
<endpoint>
<id>alfresco-noauth</id>
<name>Alfresco - unauthenticated access</name>
<description>Access to Alfresco Repository WebScripts that do not require authentication</description>
<connector-id>alfresco</connector-id>
<endpoint-url>http://localhost:8080/alfresco/s</endpoint-url>
<identity>none</identity>
</endpoint>
 
<endpoint>
<id>alfresco</id>
<name>Alfresco - user access</name>
<description>Access to Alfresco Repository WebScripts that require user authentication</description>
<connector-id>alfresco</connector-id>
<endpoint-url>http://localhost:8080/alfresco/s</endpoint-url>
<identity>user</identity>
</endpoint>
 
<endpoint>
<id>alfresco-feed</id>
<name>Alfresco Feed</name>
<description>Alfresco Feed - supports basic HTTP authentication via the EndPointProxyServlet</description>
<connector-id>http</connector-id>
<endpoint-url>http://localhost:8080/alfresco/s</endpoint-url>
<basic-auth>true</basic-auth>
<identity>user</identity>
</endpoint>
</remote>
</config>
 
</alfresco-config>

- Edited the sample above to change the "localhost:8080" part of the URLs to match your local setup.
- Save the new config file and restart Tomcat (or just redeploy share)

Thanks,
Mike

Re: HOWTO: Change the default port from 8080

Hello:

There must be some misunderstanding in this question, i`ve seen your comments but i cannot find such files and folders in my computer.
Perhaps something has changed with 3.3 version. I always feel that the main focus in your comments drives to Linux users, and im not sure wether it applies or not to windows.
Cheers

Re: HOWTO: Change the default port from 8080

pdiazs wrote:
Hello:

There must be some misunderstanding in this question, i`ve seen your comments but i cannot find such files and folders in my computer.
Perhaps something has changed with 3.3 version. I always feel that the main focus in your comments drives to Linux users, and im not sure wether it applies or not to windows.
Cheers


The instructions are the same no matter what the operating system. Which files can't you find..?

Thanks,
Mike

Re: HOWTO: Change the default port from 8080

MikeH wrote:

The instructions are the same no matter what the operating system. Which files can't you find..?

Thanks,
Mike


Hi again

1º The folder C:\Alfresco\tomcat\webapps\share\WEB-INF\classes\alfresco does not contain any sub folder called web-extension
2º I cannot find the file share-config-custom.xml.sample in any of the sub folders (messages, templates, webdata, webscripts)

Thanks a lot

Re: HOWTO: Change the default port from 8080

Ok, sorry about that - must only be included as part of an installer script.

Grab it from SVN instead: http://svn.alfresco.com/repos/alfresco-open-mirror/alfresco/HEAD/root/projects/slingshot/config/alfresco/web-extension/

Thanks,
Mike

Re: HOWTO: Change the default port from 8080

MikeH wrote:
Ok, sorry about that - must only be included as part of an installer script.

Grab it from SVN instead: http://svn.alfresco.com/repos/alfresco-open-mirror/alfresco/HEAD/root/projects/slingshot/config/alfresco/web-extension/

Thanks,
Mike

Hello again

Still the same problem, "The remote server may be unavailable or your authentication details have not been recognized"

I must have missed something

cheers

Re: HOWTO: Change the default port from 8080

Post the exact steps you've taken. I assume you can login to the Explorer client ok?

Thanks,
Mike

Re: HOWTO: Change the default port from 8080

¡¡¡ I managed to connect¡¡¡
The file to edit was afresco-global.properties located somewhere down tomcat folder (look for it through windows) There you can edit and substitute 8080 port for the selected one.

Then everythig works

Thanks a lot MikeH

Re: HOWTO: Change the default port from 8080

I'm having the same problem but I'm a bit lost. What do you change the localhost number to?

Re: HOWTO: Change the default port from 8080

Hi,

Where are you lost?
as for the localhost, i don't think you need to change it, unless you change it to your PC's IP Address. and you miss-type it, then it won't work.

@Mike,
What happens to the tomcat's port number in server.xml file under the conf directory, because I was thinking that, that's the port where the application is running from.

Regards,
Croc

Re: HOWTO: Change the default port from 8080

croc wrote:
What happens to the tomcat's port number in server.xml file under the conf directory, because I was thinking that, that's the port where the application is running from.

Yes, that's exactly where you change it. But these steps details how you then configure Share to tell it where the repository is; it could be on a completely different IP address and port so we can't assume anything!

Thanks,
Mike

Re: HOWTO: Change the default port from 8080

Thanks

Re: HOWTO: Change the default port from 8080

Hi,

I have done this very easy way on Linux box. Find all the "8080" strings by using grep command (eg: grep -r "8080" /opt/alfresco-4.0.d/). Then replace relevant port to port-80 by some common sense .

[
/opt/alfresco/tomcat/shared/classes/alfresco/web-extension/share-config-custom.xml
/opt/alfresco/tomcat/shared/classes/alfresco-global.properties
/opt/alfresco-3.4.d/tomcat/webapps/ROOT/jsp/parts/titlebar.jsp
/opt/alfresco-3.4.d/tomcat/shared/classes/alfresco/extension/wqsapi-custom.properties
/opt/alfresco-3.4.d/tomcat/webapps/ROOT/WEB-INF/classes/alfresco/repository.properties
etc....
]

Thanks
SAMU

Re: HOWTO: Change the default port from 8080

The only file necessary to change is the share-config-custom.xml

Steve

Founder EOSSOnline Limited
www.eossonline.com

Re: HOWTO: Change the default port from 8080

I think you also should change some alfresco-global.properties values so that generated links in a Document's Detail page be correct.

alfresco.context=alfresco
alfresco.host=${localname}
alfresco.port=8080
alfresco.protocol=http
 
share.context=share
share.host=${localname}
share.port=8080
share.protocol=http

This is very useful so that generated URLs could point correcly to the hostname you define. When using Alfresco behind a reverse proxy, this is also useful.

Jonathan Vargas R.
Alkaid · Open Source Business Software
Alfresco Support Partner @ Costa Rica
Google+: https://plus.google.com/u/1/109692751057729598807/about
Facebook: http://facebook.com/alkaid.cr | Web: http://www.alkaid.cr

can not find

I cannot find the file share-config-custom.xml.sample

Without editing configuration file

Hi
Some time you may not want to edit configuration file, In such scenario use IPTABLES
the command to be given is
 iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 8080
This is for LINUX machine, and It works fine

Thanks
Joseph John

Authentication for Share is still failing

Hi,

As per your HOWTO above, I have the exact same configuration in my share-config-custom.xml file, but I am still having issues.

We would like to use SSL over port 8443, instead of non-SSL over port 8080, but this is proving difficult to implement.

The ONE section which breaks Alfresco Share Authentication is:

<endpoint>
<id>alfresco</id>
<name>Alfresco - user access</name>
<description>Access to Alfresco Repository WebScripts that require user authentication</description>
<connector-id>alfresco</connector-id>
<endpoint-url>http://localhost:8080/alfresco/s</endpoint-url>
<identity>user</identity>
</endpoint>

If I amend this code to point to HTTPS and port 8443 the user authentication for Alfresco Share fails. if I put this back as above, it all works correctly!

Please can someone help me as to how I can amend this code to use SSL over port 8443 instead of non-SSL over port 8080.

Thanks
John

change url for sharepointprotocol

hi,

Is there any solution to change the default url(http://127.0.0.1:7070/alfresco) to like (http://127.0.0.1:7070/xxx)

Thanks,
Vikram

Senior Software Engineer
vikramvanama