How can I add some init code to execute when portal starting?
I need to fill some dictionaries in database.
Are you talking about Java code? Or a script on your operating system?
Implement a Startable component (see here) and register it int gatein/conf/configuration.xml via something like
Retrieving data ...