Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] Containerless CLI procedure for 7.2.0 #71

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions docs/cli-guide/master.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ include::topics/mta-cli-run-single-app.adoc[leveloffset=+3]

include::topics/mta-cli-run-multiple-apps.adoc[leveloffset=+3]

include::topics/proc_running-the-containerless-mta-cli.adoc[leveloffset=+3]

// Analyze application source code
include::topics/mta-cli-analyze.adoc[leveloffset=+3]

Expand Down
62 changes: 62 additions & 0 deletions docs/topics/proc_running-the-containerless-mta-cli.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
:_newdoc-version: 2.18.3
:_template-generated: 2024-11-15
:_mod-docs-content-type: PROCEDURE

[id="running-the-containerless-mta-cli_{context}"]
= Running the containerless CLI

You can perform an application analysis for Java applications by using the {ProductShortName} CLI that does not require installation of a container runtime.

.Prerequisites

* You have OpenJDK version 17 or later installed on your system.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alternative suggestion:

  • OpenJDK version 17 or later
  • Maven
  • python3 package
  • The JAVA_HOME environmental variable set.

* You have Maven installed on your system.
* You have Gradle installed on your system.
* The `RUN_LOCAL` environmental variable is set to `true`:
+
----
RUN_LOCAL=true
----
+
Note that if you do not set this variable to `true`, the analysis will run inside a container.
+
IMPORTANT: The analysis for languages other than Java is not affected by the RUN_LOCAL variable.
mpershina marked this conversation as resolved.
Show resolved Hide resolved

.Procedure

. Move the installed {ProductShortName} CLI `.zip` file to your `$PATH`:
+
[source,terminal,subs="attributes+"]
----
$ mv <mta_cli_zip>/<os>-kantra /usr/bin
----

. Move the requirements to the `.kantra` directory:

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be good to note here that the CLI will look in the current dir for these requirements. If not found there, it will fall back to the $HOME/.kantra location.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@eemcmullan Just to clarify if I get it right: What do you mean by the "current directory", please?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+
[source,terminal,subs="attributes+"]
----
$ mv $HOME/kantra.<os>.<arch> $HOME/.kantra
----

. Open a terminal and navigate to the directory where you installed the {ProductShortName} CLI.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the reqs are at $HOME/.kantra, the user will not need to navigate elsewhere.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ack, will attempt to rewrite it to include this info.


. Run the application analysis:
+
[source,terminal,subs="attributes+"]
----
$ mta-cli analyze-bin --overwrite --input <path_to_input> --output <path_to_output> --target <target_source>
----
mpershina marked this conversation as resolved.
Show resolved Hide resolved
+
The command arguments represent the following:

** `--overwrite`: Overwrites the output folder if it exists.
** `--input`: The application to be analyzed.
** `--output`: The output directory for the generated reports.
** `--target`: The target technology for the application migration, for example, `eap8`.


[role="_additional-resources"]
.Additional resources

* xref:installing-downloadable-cli-zip_cli-guide[Installing the CLI .zip file]