Foren

Portal.Properties location, where is it?

Vijay Mudivedu, geändert vor 12 Jahren.

Portal.Properties location, where is it?

New Member Beiträge: 20 Beitrittsdatum: 18.07.11 Neueste Beiträge
Hi,

I am trying to figure the portal.properties file to understand what is configured there from two days. Do you experts know the exact location of the file?

I was trying to make a few customizations in the portal, for example:

#
# Set the list of supported wiki formats and the default wiki format.
#
wiki.formats=creole,html
wiki.formats.default=html


I tried to do this in the Portal-Ext.properties file by adding the two lines above of above code and saving the file. However, changing here has no impact on the portal. I am missing any further steps here?

Please help me if I am doing any mistake..

Thanks,
VJ
thumbnail
Tanweer Ahmed ., geändert vor 1 Jahr.

RE: Portal.Properties location, where is it?

Expert Beiträge: 322 Beitrittsdatum: 11.03.10 Neueste Beiträge
Vijay Mudivedu:
Hi,

I am trying to figure the portal.properties file to understand what is configured there from two days. Do you experts know the exact location of the file?

I was trying to make a few customizations in the portal, for example:

#
# Set the list of supported wiki formats and the default wiki format.
#
wiki.formats=creole,html
wiki.formats.default=html


I tried to do this in the Portal-Ext.properties file by adding the two lines above of above code and saving the file. However, changing here has no impact on the portal. I am missing any further steps here?

Please help me if I am doing any mistake..

Thanks,
VJ


Hi Vijay,

You can find the portal.properties in portal src code.If you want to override any entry, given in portal.properties,You have to create portal-ext.properties and then override the entry.

Hope this helps,
Regards,
Tanweer
mPowerian-BoschLer
Vijay Mudivedu, geändert vor 12 Jahren.

RE: Portal.Properties location, where is it?

New Member Beiträge: 20 Beitrittsdatum: 18.07.11 Neueste Beiträge
Hi Tanweer,

Couple of questions from the below qutoes:

I found the portal.properties at: D:\liferay-portal-6.0.6\tomcat-6.0.29\webapps\ROOT\WEB-INF\lib\portal-impl. Is this the right location of the "SRC Code" you mentioned below. I am completely new to understanding the LifeRay.

I also created a file portal-ext.properties. However in the portal.properties is mentioned as:

include-and-override=${liferay.home}/portal-ext.properties.

Do you know what should I use for {liferay.home}?
thumbnail
Leo Pratlong, geändert vor 12 Jahren.

RE: Portal.Properties location, where is it?

Expert Beiträge: 363 Beitrittsdatum: 06.07.10 Neueste Beiträge
Hi,

if you want to configure your Liferay, you have to write a portal-ext.properties :
you can write on the home of your user (on linux /home/username/portal-ext.properties; on Max /Users/username/portal-ext.properties; on Windows C:\Local Settings\.username or something like that. Google it ;) ).

You can also put this file on a plugin Ext to override the real portal.properties. And you can put it everywhere by specifying its location. But just try to do it by putting it in your "home" folder.

If nothing happens, there two possible reasons :
- Liferay does not have the right to read the file : so take a look on the right associated to the file and change it.
- You have configure options through the Liferay User Interface (the Control Panel) : when you change a value on the Control Panel, the value is changed in database and it will override any configuration from the portal-ext.properties for this option. So, ensure you do not have change configuration throught your Control Panel (if you did it, you can delete corresponding lines in database, but it's risky).


Good luck!
Megha Shah, geändert vor 12 Jahren.

RE: Portal.Properties location, where is it? (Antwort)

New Member Beiträge: 21 Beitrittsdatum: 29.09.11 Neueste Beiträge
Vijay Mudivedu:
Hi Tanweer,

Couple of questions from the below qutoes:

I found the portal.properties at: D:\liferay-portal-6.0.6\tomcat-6.0.29\webapps\ROOT\WEB-INF\lib\portal-impl. Is this the right location of the "SRC Code" you mentioned below. I am completely new to understanding the LifeRay.

I also created a file portal-ext.properties. However in the portal.properties is mentioned as:

include-and-override=${liferay.home}/portal-ext.properties.

Do you know what should I use for {liferay.home}?


Hi,
You can write a new file called portal-ext.properties and place it under this location ROOT\WEBINF\classes and put whichever properties you want to overwrite here. Then just re-start your server to get the changes into effect.
This should help.
Vijay Mudivedu, geändert vor 12 Jahren.

RE: Portal.Properties location, where is it? (Antwort)

New Member Beiträge: 20 Beitrittsdatum: 18.07.11 Neueste Beiträge
HUH!! Thanks for helping me out.. It finally worked.emoticon

This step helped me ... Then just re-start your server to get the changes into effect.

1. On the windows machine, I had to go to D:\ liferay-portal-6.0.6\tomcat-6.0.29\bin:
2. Opened the command prompt: Selected the above path and ran the "Shutdown.bat" file.
3. Opened the command prompt: Selected the above path and ran the "Startup.bat" file.

Rgds,
Vijay
thumbnail
Javier Solana, geändert vor 9 Jahren.

RE: Portal.Properties location, where is it?

Junior Member Beiträge: 59 Beitrittsdatum: 26.06.14 Neueste Beiträge
Thanks! after hours of searching, this is the easiest way that I found to get things work!
I mean the ROOT\WEBINF\classes\portal-ext.properties file
thumbnail
darren rose, geändert vor 9 Jahren.

RE: Portal.Properties location, where is it?

Regular Member Beiträge: 215 Beitrittsdatum: 04.04.15 Neueste Beiträge
Javier Solana:
Thanks! after hours of searching, this is the easiest way that I found to get things work!
I mean the ROOT\WEBINF\classes\portal-ext.properties file



can't I acheive this using a hook and adding a portal-ext.properties file to the generated web app?
thumbnail
David H Nebinger, geändert vor 9 Jahren.

RE: Portal.Properties location, where is it?

Liferay Legend Beiträge: 14919 Beitrittsdatum: 02.09.06 Neueste Beiträge
No, and Javier's placement for portal-ext.properties is deprecated.

This is not a file that should be hookable or anything. It is a settings file that controls how the portal functions and is not meant to be that dynamic.

The appropriate place for the file is the $LIFERAY_HOME directory, this is also the directory where you find the data directory and the deploy directory. This too is outside of the application server folder which should enforce the understanding that it is not hookable nor deployable.
thumbnail
darren rose, geändert vor 9 Jahren.

RE: Portal.Properties location, where is it?

Regular Member Beiträge: 215 Beitrittsdatum: 04.04.15 Neueste Beiträge
David H Nebinger:
No, and Javier's placement for portal-ext.properties is deprecated.

This is not a file that should be hookable or anything. It is a settings file that controls how the portal functions and is not meant to be that dynamic.

The appropriate place for the file is the $LIFERAY_HOME directory, this is also the directory where you find the data directory and the deploy directory. This too is outside of the application server folder which should enforce the understanding that it is not hookable nor deployable.


Ok, assuming I will need to create an Ext plugin, can I get away with just creating the ext-impl and ext-web maven modules?
thumbnail
David H Nebinger, geändert vor 9 Jahren.

RE: Portal.Properties location, where is it?

Liferay Legend Beiträge: 14919 Beitrittsdatum: 02.09.06 Neueste Beiträge
WTH? What part of "no it should not be deployed" didn't you get?

Sure, do it with a partial EXT plugin. That would seem to be just the right nonsense you should keep trying.
thumbnail
darren rose, geändert vor 9 Jahren.

RE: Portal.Properties location, where is it?

Regular Member Beiträge: 215 Beitrittsdatum: 04.04.15 Neueste Beiträge
David H Nebinger:
WTH? What part of "no it should not be deployed" didn't you get?

Sure, do it with a partial EXT plugin. That would seem to be just the right nonsense you should keep trying.



very helpful
thumbnail
David H Nebinger, geändert vor 9 Jahren.

RE: Portal.Properties location, where is it?

Liferay Legend Beiträge: 14919 Beitrittsdatum: 02.09.06 Neueste Beiträge
Your sarcasm aside, it was helpful.

No it should not be deployed. Period. It's not even supposed to be in the webapps directory at all if you do things the right way.

No, you cannot deploy only part of an ext plugin. It's either all or none. You can't deploy half of a portlet, half of a hook, half of a theme, ... It is what it is.

Yes I understand you're trying to disable having to change the password the first time you log in. Yes I understand you haven't figured it out so far. But that doesn't mean that you're going to find some hacked solution in any of these odd scenarios you keep posting about that will get you there.
thumbnail
darren rose, geändert vor 9 Jahren.

RE: Portal.Properties location, where is it?

Regular Member Beiträge: 215 Beitrittsdatum: 04.04.15 Neueste Beiträge
David H Nebinger:
Your sarcasm aside, it was helpful.

No it should not be deployed. Period. It's not even supposed to be in the webapps directory at all if you do things the right way.

No, you cannot deploy only part of an ext plugin. It's either all or none. You can't deploy half of a portlet, half of a hook, half of a theme, ... It is what it is.

Yes I understand you're trying to disable having to change the password the first time you log in. Yes I understand you haven't figured it out so far. But that doesn't mean that you're going to find some hacked solution in any of these odd scenarios you keep posting about that will get you there.


I have placed a portal-ext.properties in my liferay 6.2 home folder

the file contains

passwords.default.policy.change.required=false

and yet, when users login for the first time, they are asked to change their password - how do I prevent this?

thanks
thumbnail
Suresh Nimmakayala, geändert vor 9 Jahren.

RE: Portal.Properties location, where is it?

Liferay Master Beiträge: 690 Beitrittsdatum: 18.08.04 Neueste Beiträge
try
control panel --> password Policies -->Default Password policy -- edit --> uncheck Change Required under Changeable

it is working for me


Regards
Suresh
thumbnail
darren rose, geändert vor 9 Jahren.

RE: Portal.Properties location, where is it?

Regular Member Beiträge: 215 Beitrittsdatum: 04.04.15 Neueste Beiträge
Suresh Nimmakayala:
try
control panel --> password Policies -->Default Password policy -- edit --> uncheck Change Required under Changeable

it is working for me


Regards
Suresh


Yes, that works, but I want to avoid the above mentioned manual steps, and specify the intent in the portal-ext.properties or similar, which seems possible, but that isn't taking affect
thumbnail
David H Nebinger, geändert vor 9 Jahren.

RE: Portal.Properties location, where is it?

Liferay Legend Beiträge: 14919 Beitrittsdatum: 02.09.06 Neueste Beiträge
darren rose:
I want to avoid the above mentioned manual steps, and specify the intent in the portal-ext.properties or similar, which seems possible, but that isn't taking affect


There are many properties that come from portal-ext.properties only at first launch; subsequently the values must be changed using the interface.

This is one example of that.

If you set the property before the first launch of Liferay (when the database is being populated), it will be used in configuring the password policy that is then stored in the database.
thumbnail
darren rose, geändert vor 8 Jahren.

RE: Portal.Properties location, where is it?

Regular Member Beiträge: 215 Beitrittsdatum: 04.04.15 Neueste Beiträge
Using the API, I guess this is possible?

policy = PasswordPolicyLocalService.getDefaultPasswordPolicy(companyId)
policy.setChangeRequired(false)
PasswordPolicyLocalService.updatePasswordPolicy(policy)
thumbnail
David H Nebinger, geändert vor 8 Jahren.

RE: Portal.Properties location, where is it?

Liferay Legend Beiträge: 14919 Beitrittsdatum: 02.09.06 Neueste Beiträge
That would be the way I'd do it. I don't know if it will work from the scripting console, but it's how I'd try it within code...
thumbnail
darren rose, geändert vor 8 Jahren.

RE: Portal.Properties location, where is it?

Regular Member Beiträge: 215 Beitrittsdatum: 04.04.15 Neueste Beiträge
David H Nebinger:
That would be the way I'd do it. I don't know if it will work from the scripting console, but it's how I'd try it within code...


It works.

I have created 2 custom Liferay plugins of type Hook for custom configuration and external authentication.

Really simplifies deployment to 16 Liferay servers, where we also have custom fields, roles, groups, and users authenticated via web services external to liferay.

regards
thumbnail
David H Nebinger, geändert vor 8 Jahren.

RE: Portal.Properties location, where is it?

Liferay Legend Beiträge: 14919 Beitrittsdatum: 02.09.06 Neueste Beiträge
Well then you could add a startup action. Would check the value of the changeRequired field and set it/update if necessary. Means that you wouldn't have any control over it at in the control panel, but sounds like you might not want it there anyway.
thumbnail
darren rose, geändert vor 8 Jahren.

RE: Portal.Properties location, where is it?

Regular Member Beiträge: 215 Beitrittsdatum: 04.04.15 Neueste Beiträge
David H Nebinger:
Well then you could add a startup action. Would check the value of the changeRequired field and set it/update if necessary. Means that you wouldn't have any control over it at in the control panel, but sounds like you might not want it there anyway.


Yes, doing exactly that, now if I could allow numeric screen names via the API I would be very happy