cancel
Showing results for 
Search instead for 
Did you mean: 

Modifying e-mail Notification URL ?

goozey
Champ in-the-making
Champ in-the-making
I have alfresco 4.2.e Community edition installed on my Debian test environment server. I have a domainname designated for the server and currently using a reverse proxy via Nginx to enable SSL (https://) using the following settings within nginx:

server {
        listen 443;
        server_name alfresco.companyname.com;
        ssl                     on;
        ssl_certificate         /etc/ssl/certs/alfresco.companyname.com.crt;
        ssl_certificate_key     /etc/ssl/private/alfresco.companyname.com.key;
        rewrite ^/$ /share;

        location / {
        root /opt/alfresco-4.2.e/tomcat/webapps/share/;
        proxy_pass https://localhost:8443;

        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header host $host;
        proxy_set_header X-Forwarded-Server $host;
        }
        }


Basically i want users to be able to access the site internally and externally which is working fine so far, all they have to do is type in alfresco.company.com into the url bar of their browser.

Now the problem:
When i start a workflow and check the email notification checkbox it sends out an email (as intended) but the link is… not optimal, this is what i am receiving:

https://alfresco.companyname.com:8080/share/page/task-edit?taskId=activiti$245

This is obviously somewhat breaking things. Is there any way on how I could remove the ":8080" from the url?
I have checked the forums and some suggestions have been to edit the email notifications code itself which would be this part within the wf-email_de.html.ftl file if i am not mistaken:


<#if args.workflowPooled == true>
                                                <p>Klicken Sie auf diesen Link um die Aufgabe einzusehen:</p>
                                                <p><a href="${shareUrl}/page/task-details?taskId=${args.workflowId}">${shareUrl}/page/task-details?taskId=${args.workflowId}</a>
                                             <#else>
                                                <p>Klicken Sie auf diesen Link um die Aufgabe zu ändern:</p>
                                                <p><a href="${shareUrl}/page/task-edit?taskId=${args.workflowId}">${shareUrl}/page/task-edit?taskId=${args.workflowId}</a>
                                             </#if>


What i do not understand is where the ${shareUrl} value is defined/set and where i coudl edit this so the ":8080" is removed.
I welcome any and all suggestions.

Kind regards,
Alex
11 REPLIES 11

eyitaya
Champ in-the-making
Champ in-the-making

If you have this in your config file and the port is still showing in the task link  

dir.root=/opt/alfresco-4.2.e/alf_data

alfresco.context=alfresco
alfresco.host=alfresco.companyname.com
alfresco.port=8080
alfresco.protocol=http

share.context=share
share.host=alfresco.companyname.com
share.port=8080
share.protocol=https

All you need to change is  share.port=443.

I guess you should be fine.

hiten_rastogi1
Star Contributor
Star Contributor

Hey,

To anyone facing this issue just change the prop share.port and alfresco.port to 80 instead of 8080.

share.port=80
alfresco.port=80

You will see the url changed

FROM:

https://alfresco.companyname.com:8080/share/page

TO:

https://alfresco.companyname.com/share/page