Step 3: Analyze your application
After you have completed setup and initialization tasks on your servers, you can begin to analyze your applications. During the analysis phase, you take inventory of the applications running on your application servers, and analyze specific applications within your inventory.
Choose the tab that matches your operating system (OS) platform to continue:
- Linux
-
On the application server, follow these steps to prepare to containerize the applications.
Prepare for containerization
-
Run the inventory command as follows to list the Java applications that are running on your server.
$
sudo app2container inventory
The output includes a JSON object collection with one entry for each application. Each application object will include key/value pairs as shown in the following example.
"
java-app-id
": { "processId":pid
, "cmdline": "/user/bin/java ...", "applicationType": "java-apptype
" } -
Locate the application ID for the application to containerize in the JSON output of the inventory command, and then run the analyze command as follows, replacing
java-app-id
with the application ID that you located.$
sudo app2container analyze --application-id
java-app-id
The output is a JSON file,
analysis.json
, stored in the workspace directory that you specified when you ran the init command. -
(Optional) You can edit the information in the
containerParameters
section ofanalysis.json
as needed before continuing to the next step.
-
- Windows
-
On the application server, follow these steps to prepare to containerize your applications.
Prepare for containerization
-
Run the inventory command as follows to list the ASP.NET applications that are running on your server.
PS>
app2container inventory
The output includes a JSON object collection with one entry for each application. Each application object will include key/value pairs as shown in the following example.
"
iis-app-id
": { "siteName":My site name
, "bindings": "http/*:80:
", "applicationType": "iis", "discoveredWebApps": [ "app1
", "app2
" ] } -
Locate the application ID for the application to containerize in the JSON output of the inventory command, and then run the analyze command as follows, replacing
iis-app-id
with the application ID that you located.PS>
app2container analyze --application-id
iis-app-id
The output is a JSON file,
analysis.json
, stored in the workspace directory that you specified when you ran the init command. -
(Optional) You can edit the information in the
containerParameters
section ofanalysis.json
as needed before continuing to the next step.
-