Since version 6.3, AEM allows the admin password to be set using the command line when installing a new instance.
With earlier versions of AEM, the password for the admin account, along with the password for various other consoles had to be changed after installation.
This feature adds the facility of setting a new administrator password for the repository and the Servlet Engine during the installation of an AEM instance, thus eliminating the need to do it manually afterwards.
Please note that feature does not cover the Felix Console, for which the password needs to be changed manually. For more information, see the relevant Security Checklist section.
This feature will trigger automatically if you choose to install AEM via the command line, as opposed to double clicking the JAR from a filesystem explorer.
The general synthax for running an AEM instance from the command line is:
java -jar aem6.3.jar
Upon running the instance from the command line, you will be presented with the option to change the admin password during the installation process:
The prompt to change the admin password will only appear during the installation of a new AEM instance.
You can also choose to specify the password from a properties file. This is done by using the -nointeractive flag combined with the the -Dadmin.password.file system property.
Below is an example:
java -Dadmin.password.file =/path/to/passwordfile.properties -jar aem6.3.jar -nointeractive
admin.password = 12345678
If you simply use the -nointeractive parameter without the -Dadmin.password.file system property, AEM will use the default admin password without asking you to change it, essentially replicating behaviour from earlier versions. This non interactive mode can be used for automated installations using the command line in an installation script.