Using the Liferay Service’s Shell
Sometimes you need direct access to the system to see what’s happening. Kyle wants to use the Liferay service’s shell to view the directory structure and verify database creation.
Here, you’ll use the shell and directly query a Liferay instance’s database from the console.
Accessing the Shell
Access the Liferay service’s shell via the service’s page.
In the Liferay Cloud console, navigate to your UAT environment.
Click Services on the left side of the screen.
Click the Liferay service.
Click the Shell tab.
lsinto the shell to see the Liferay Home directory contents.
Changes you make to your Liferay instance through the shell are not permament. They are overwritten the next time your service restarts.
Using the MySQL Client
Next, use the MySQL client to view your Liferay instance’s database.
mysqlinto the shell to log into the MySQL client with the default user.note
Logging in with the default database user gives read-only access to the database. If you must manipulate data, log in with the database service’s credentials.
show tables;to show a list of all existing tables that you can scroll through.
Try running another query to see a list of all vocabularies across all sites:
select vocabularyId, name, groupId from AssetVocabulary;
Finally, log out of the MySQL client when you are finished:
Next, you’ll deploy a simple custom service to your UAT environment.