{"id":22389820,"url":"https://github.com/entando/entando-pam-app","last_synced_at":"2026-02-12T05:04:21.270Z","repository":{"id":37312846,"uuid":"203572363","full_name":"entando/entando-pam-app","owner":"entando","description":null,"archived":false,"fork":false,"pushed_at":"2022-06-30T15:23:16.000Z","size":9594,"stargazers_count":0,"open_issues_count":4,"forks_count":1,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-08-28T00:58:27.754Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PLSQL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/entando.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-08-21T11:43:33.000Z","updated_at":"2020-03-20T13:42:45.000Z","dependencies_parsed_at":"2022-09-10T07:21:12.776Z","dependency_job_id":null,"html_url":"https://github.com/entando/entando-pam-app","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/entando/entando-pam-app","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/entando%2Fentando-pam-app","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/entando%2Fentando-pam-app/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/entando%2Fentando-pam-app/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/entando%2Fentando-pam-app/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/entando","download_url":"https://codeload.github.com/entando/entando-pam-app/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/entando%2Fentando-pam-app/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29359360,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-12T01:03:07.613Z","status":"online","status_checked_at":"2026-02-12T02:00:06.911Z","response_time":55,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-05T03:13:20.659Z","updated_at":"2026-02-12T05:04:21.192Z","avatar_url":"https://github.com/entando.png","language":"PLSQL","funding_links":[],"categories":[],"sub_categories":[],"readme":"# entando-pam-app-5.2.0\nAn Entando App with Red Hat Process Automation Manager integration for version 5.2.0\nTo run locally for development purposes and no dependency on docker, run this in your terminal:\n`mvn clean package -Pjetty-local -Pderby jetty:run -DskipDocker -Djetty.port=8082`\n\n# The Docker host\n\nThis Maven project makes extensive use of Docker. In order to get this Maven project to integrate \nwith Docker as intended, you may need to specify the ip address where  your Docker daemon is running. \nIn this document we generally pass that as the '-Ddocker.host.ip' JVM system property.\nIf you are running Docker directly on Linux, this is optional as the Maven plugin is configured \nto use your Docker network's default gateway running on 172.17.0.1. Alternatively, you could also use your machine's\nip address. Don't use 'localhost' as this creates confusion when accessed from Docker containers and the container\nattempts to connect to itself.\n\nSome installations of Docker runs the Docker services inside its own VM. This is usually the case in the following\nenvironments:\n1. Older Windows based Docker installations\n2. Older Apple based Docker installtions\n3. Minishift, a lightweight preconfigured VM hosting Openshift.\n4. Minikube, a lightweight preconfigured VM hosting Kubernetes\n\nIn all of these cases, your Docker host would be the ip address of the VM in question.\n\nIf you do not wish to specify the '-Ddocker.host.ip' JVM system property with every Maven command you run, you could\nalso override that property in your Maven pom.xml file. Just remember to revert to the value that your build server\nrequires it to be before committing your code. Assuming your build server is a Linux environment, the correct value\nwould be 172.17.0.1\n\n\n# Local development flow\n\nFor local development, we have included the Maven Jetty plugin that runs the Eclipse Jetty Java web server directly \non your current project. In other words, it does NOT create a Docker container for any Java web server in this mode.\nThe advantage of doing development in this mode is that your changes to your web resources will reflect \ninstantaneously, leveraging Jetty's 'hot-deploy'  feature. \n\nWhen running in this mode, you may also prefer to use the embedded Derby database as it is a bit faster starting \nup your app that way. The resulting Derby databases are hosted in ${basedir}/target/derby on your local \nfile system. Since Jetty itself is also running locally, it will have direct access to these database files without\nthe complexity of Docker volumes.\n\nTo activate this configuration, run the following command (note that the docker.host.ip property is \noptional on Linux):\n\n  `mvn  clean package -Pjetty-local -Pderby docker:start jetty:run -Ddocker.host.ip=\u003cDOCKER-HOST\u003e`\n\nNotice that the first profile specified, 'jetty-local', configures your Java web server environment of choice, \nwhereas the second profile,  'derby' configures your database of choice. This is the general pattern we \nfollowed throughout this Maven project.\n\nThe Maven lifecycle phase, 'package' compiles your classess and packages them with your dependencies and other \nresources in a WAR. This Maven project is also configured to build the necessary Docker images during the 'package' phase,\nbut more on that later. The Maven goal, 'docker:start' starts the prebuilt Entando AppBuilder image, \nand sets it up to point to the Entando Engine instance running locally in Jetty. This local instance is started \nup by the 'jetty:run' Maven goal.\n\nAfter running this command, you would be able to access the AppBuilder at http://\\\u003cDOCKER-HOST\\\u003e:5000 where \\\u003cDOCKER-HOST\\\u003e\nis the ip address where you Docker server is running, as explained earlier. You can access the Entando Engine at\nhttp://localhost:8080/entando-pam-ap. If you have changed the Maven artifactId of this project, replace the the the last\nsegment of that URL, also referred to as the web context of the app, from 'entando-pam-app' to the artifactId you have\nchosen. \n\nYou can stop the Jetty server directly by typing \u003cCTRL\u003e-C. The AppBuilder container will however still be running in the\nbackground. If you wish to stop this container, you can either kill it from your Docker commandline, or you could run\n\n`mvn -DskipDocker docker:stop -Ddocker.host.ip=\u003c\u003cDOCKER-HOST\u003e\u003e`\n\nOnce you are happy with the state of your app, remember to backup the database locally using the database \nbackup feature in the Entando Administration app. When running your app using this 'jetty-local' profile, \nthose database backups will be stored locally under src/main/webapp/protected, where it will then be picked \nup by the Entando Docker images. \n\nIf you wish to reset the Derby databases, please delete the folder target/derby after you have stopped the \njetty server. This will result in entirely new Derby databases being created, either based on the \ninitialization logic of the Entando plugins you have selected, or, when present, the last database backups \nyou have made to src/main/webapp/protected.  \n\n# Running the app in a production-ready server\n\nIf you want to run your app in an application server that you would like to use in production, you have a choice of \nusing our JBoss EAP 7.1 base image or our Wildfly 12 base image. We also have a Jetty base image you can use, although\nthis may not be ideal for production deployments. When using one of these Java web servers, you would \nprobably also want to use one of our production ready database images, such our MySQL or PostgreSQL images. Derby \nis still available, but the Derby databases would be embedded in the image hosting the Java web server, and would\nnot be packaged in a separate image. This may not be ideal for certain clustering requirements where a shared database\nis required. \n\nYou can select your combination of Java web server image and database management systems  by using the \npreviously highlighted pattern of activating the relevant profiles. You would combine the profile configuring \nyour Java web server and the profile configuring your DBMS. For example, if you wish to run \nJBoss EAP and PostgreSQL, run this command:\n\n`mvn clean package -Peap -Ppostgresql docker:start -Ddocker.host.ip=\u003c\u003cDOCKER-HOST\u003e\u003e`\n\nIf you wish to run Wildfly 12 and MySQL 5.7, run this command:\n\n`mvn clean package -Pwildfly -Pmysql docker:start -Ddocker.host.ip=\u003c\u003cDOCKER-HOST\u003e\u003e`\n\nIf you wish to run Jetty 09.4 in a Docker image, combined with an embedded Derby database, you can activate the \n'jetty-container' and 'derby' profiles. Note that we use the 'jetty-container' profile as opposed to the \n'jetty-clocal' profile. Since the Docker container will be starting Jetty, there is no need to run \nthe local Maven Jetty plugin goal of jetty:run. You can just run the following command:\n\n`mvn clean package -Pjetty-container -Pderby docker:start -Ddocker.host.ip=\u003c\u003cDOCKER-HOST\u003e\u003e`\n\nYou can also combine Wildfly and Derby, which can be useful for proofs of concept. However, combining JBoss EAP and Derby \nis not recommended as the JBoss EAP image is pre-configured for clustering, and Derby in embedded mode doesn't support\nclustering. As long as neither the 'jetty-local' profile nor the 'derby' profiles are used, both the Java web server image \nand the DBMS image that are produced by this command can be used in a production environment. These should preferably\ndeployed to a container orchestration product such as Docker Swarm, Kubernetes or Openshift. Please consult our \ndocumentation at http://docs.entando.com/#_designing_your_pipeline_for_entando for further guidance on how to setup\nyour pipelines for Entando. \n\nNB!! Please note that, should you choose to use JBoss EAP in a production environment, you need to have the necessary \nsubscription from RedHat. \n\n  \n# Advanced options\n\nOnce you are comfortable using this Maven project to develop locally using Jetty, and you have played around with\nsome of the Docker combinations, you are now free to explore some more advanced and interesting options.\n\n## Mapping services to known ports\n\nWhen it comes to mapping Docker container ports to ports on the Docker host, the default behaviour of the \nDocker Maven Plugin is to find a port available in the ephemeral range (32768 to 61000) and map it to the container\nport. This works very well for a build server where you typically do not know which ports are available.\nHowever, if you would like to view your Docker containers on your\nlocal machine, running `docker ps` each time to see which ports the various services are running on can be rather\ncumbersome. If you would like to export each service to a know port, just activate the 'local-ports' profile. When\nthis profile is activated, the Maven Docker Plugin will use the ports specified in the properties defined in the\nprofile. Their defaults values are as follows:\n\n* Java web server: 8080\n* App Builder: 5000\n* MySQL: 3306\n*PostgreSQL: 5432\n\nYou are free to changes these properties to fit your needs.\n\n## Using Jetty hot deploy with MySQL or PostgreSQL\n\nIf you would like to use MySQL or PostgreSQL as a database, you just need to combine the correct DBMS profile with\nthe 'jetty-local' profile. The following command will start the MySQL database to back Entando from Jetty\n  \n  `mvn  clean package -Pjetty-local -Pmysql docker:start jetty:run -Ddocker.host.ip=\u003c\u003cDOCKER-HOST\u003e\u003e`\n  \nThis command will build a MySQL image with pre-built databases inside it. These databases will get copied across to\na Docker volume named '${project.artifactId}-entando-db-data' as the container starts up. Any subsequent changes will\nbe stored in that Docker volume. You would also be able to connect to your local MySQL instance by connecting to\n\u003c\u003cDOCKER-HOST\u003e\u003e:3306/portdb using the credentials portdbuser:portdb123 and to\n\u003c\u003cDOCKER-HOST\u003e\u003e:3306/servdb using the credentials servdbuser:servdb123. You can change the credentials for MySQL by\nchanging the Maven properties \u003cportdb.username\u003e:\u003cportdb.password\u003e and \u003cservdb.username\u003e:\u003cservdb.password\u003e in the MySQL\nprofile.\n\nYou can terminate Jetty directly from the console by typing \u003cCTRL\u003e-C. The MySQL container will however still be running.\nIf this is what you had in mind, then you can start Jetty the next time without the 'docker:start' goal. In order to \nbe consistent, you should also bypass the 'package' lifecycle phase so as not to build a new database image. The following command\nwill simply start Jetty and connect it to your existing database container:\n\n  `mvn  -Pjetty-local -Pmysql jetty:run -Ddocker.host.ip=\u003c\u003cDOCKER-HOST\u003e\u003e`\n\nYou can stop the MySQL container (and the AppBuilder container) by running:\n\n    `mvn -DskipDocker=false docker:stop -Ddocker.host.ip=\u003c\u003cDOCKER-HOST\u003e\u003e`\n\nThis will remove the MySQL container, but the underlying databases will remain in tact in the '${project.artifactId}-entando-db-data'\nvolume. As mentioned before, every time you run the 'package' lifecycle, the database image will be rebuilt. This can take\na bit of time, and is only really required if the database structure changes, such as when you add or remove an Entando\nplugin the modifies the database structure. So if rebuilding the database image is\nnot what you want, but you still need to start the database container, skip the clean and package phases entirely:\n\n  `mvn  -Pjetty-local -Pmysql docker:start jetty:run -Ddocker.host.ip=\u003c\u003cDOCKER-HOST\u003e\u003e`\n\nAll of these rules and features also apply to the PostgreSQL image and the 'postgresql' profile, except that the \ndefault port for PostgreSQL changes to 5432. Please remember to delete the database volume if you wish to switch \nfrom MySQL  to PostgreSQL or vice versa. You need to do this from the Docker command line (where\n{project.artifactId} is the artifactId you have chosen for your project, 'entando-pam-app' by default):\n\n    `docker volume rm ${project.artifactId}-entando-db-data'\n   \n## Using EAP or Wildfly\n\nIn order to activate one of the JBoss based images, you can use either the 'eap' or the 'wildfly' profile in\nthe place of the Java web server profile, where we previously used 'jetty-local'\n\n\n`mvn clean package -Peap -Ppostgresql docker:start -Ddocker.host.ip=\u003c\u003cDOCKER-HOST\u003e\u003e` \n\nThe 'docker:start' goal starts the containers in the background and then terminates the Maven process. You can\nterminate these Docker container running the following command:\n\n`mvn -DskipDocker=false docker:stop`\n\nIt is important to understand that the 'eap' and 'wildfly' profiles were optimized for execution on a build server.\nIt is generally a bad idea to assume that certain ports are available on a build server. For this reason, these\nprofiles were configured to use the Docker Maven Plugin's dynamic port assignment capabilities. When of of these \nprofiles is active, the Docker Maven Plugin will look for available ports on the Docker host and map the container\nports to the available ports. The following ports will be mapped dynamically from its container to the dynamically\nselected port on the host:\n\n* App Builder Container: 5000\n* EAP/Wildfly Container: 8080\n* MySQL container: 3306\n* PostgreSQL container: 5432\n\nIf you execute one of these profiles as is, you would therefore have to go and look for these port mappings from\nthe Docker command line running \n\n     `docker ps`\n     \nThe result will look something like this:\n\n```\nCONTAINER ID  IMAGE                                          COMMAND                  CREATED        STATUS        PORTS                                           NAMES\n34038c73597f  entando/appbuilder:5.1.0-SNAPSHOT              \"container-entrypoin…\"   2 minutes ago  Up 2 minutes  8080/tcp, 172.17.0.1:32783-\u003e5000/tcp            confident_hertz\na9d36673728f  entandosamples/entando-pam-app:5.1.0-SNAPSHOT  \"/bin/sh -c \\\"${STI_S…\"  2 minutes ago  Up 2 minutes  8443/tcp, 8778/tcp, 172.17.0.1:32782-\u003e8080/tcp  entando-pam-app-engine\nd897790cf3a3  entandosamples/entando-pam-app-db              \"container-entrypoin…\"   2 minutes ago  Up 2 minutes  172.17.0.1:32781-\u003e5432/tcp                      entando-pam-app-dbms\n```     \n\nNotice the dynamically allocated ports 32781, 32782 and 32783 for the DBMS, EAP and AppBuilder containers respectively. \nYou will also notice a properties files generated to 'target/ports.propertes' containing the ports and the ip address\nof the the Docker host, all matched to properties that are used from Maven. This can be useful if you wish to lookup\nthe dynamically allocated ports from a different process, such as the one running your integration tests.\n\nThis dynamic allocation of ports may not be the behaviour you are looking for when experimenting with the resulting \ncontainers on your local machine. If you would like for AppBuilder to run on port 50000 as expected, the Entando Engine\non port 8080 as expected, MySQL on port 3306 and PostgreSQL on port 5432, activate the 'local-ports' profile:\n\n`mvn clean package -Peap -Ppostgresql -Plocal-ports docker:start -Ddocker.host.ip=\u003c\u003cDOCKER-HOST\u003e\u003e` \n\nYou can now access all the services on the port you would be expecting them to be if you were doing local development\nusing the 'jetty-local' profile. When running with the fixed local ports option, you are now free to stop individual containers\ndirectly using the Docker command line. This is particularly useful if you made changes that will affect the Entando\nEngine, but you need to retain the existing database. You can stop and rebuild the Entando Engine as follows (where \n${project.artifactId refers to the artifactId you have chosen or 'entando-pam-app' by default):\n\n```\ndocker stop ${project.artifactId}-engine\ndocker rm ${project.artifactId}-engine\nmvn clean package -Peap -Ppostgresql -Plocal-ports -DskipDatabaseImage=true -DskipAppBuilderImage=true -DautoCreateNetwork=false docker:start -Ddocker.host.ip=\u003c\u003cDOCKER-HOST\u003e\u003e` \n```\n\nIn the last command, you will notice that this command skips the database and AppBuilder images. It also instructs the\nDocker Maven plugin not to automatically remove and recreate the custom network, as the previously started AppBuilder\nand database containers would still have active endpoints in the custom network.\n \n## Creating your own profiles\n\nYou are also free to add your own profiles to the Maven pom. All of the Maven plugins in the pom have been parameterized\nwith Maven properties. The profiles simply turn certain features on and off, and populate certain variables to support\nthose features. Just copy the properties from the various profiles together in your own profile. Let's say you want\nto do local development using Wildfly and PostgreSQL, and you always want them to start on known ports, simply aggregate\nall the properties from the 'wildfly' 'postgresql' and 'local-ports' properties. You could even make this the \ndefault profile. Your resulting profile would look something like this:\n\n```\n        \u003cprofile\u003e\n            \u003cid\u003emy-wildfly\u003c/id\u003e\n            \u003cactivation\u003e\n                \u003cactiveByDefault\u003etrue\u003c/activeByDefault\u003e\n            \u003c/activation\u003e\n            \u003cproperties\u003e\n                \u003c!--Image configuration --\u003e\n                \u003cskipDocker\u003efalse\u003c/skipDocker\u003e\n                \u003cskipAppBuilderImage\u003efalse\u003c/skipAppBuilderImage\u003e\n                \n                \u003centando.engine.address\u003e${docker.host.address}\u003c/entando.engine.address\u003e\n                \u003capp.builder.depends.on\u003e${project.artifactId}-engine\u003c/app.builder.depends.on\u003e\n\n                \u003cskipServerImage\u003efalse\u003c/skipServerImage\u003e\n                \u003cjboss.home.in.image\u003e/wildfly\u003c/jboss.home.in.image\u003e\n                \u003cserver.base.image\u003eentando-wildfly12-base\u003c/server.base.image\u003e\n\n                \u003cderby.base.folder\u003e/entando-data/databases\u003c/derby.base.folder\u003e\n                \u003cskipDatabaseImage\u003efalse\u003c/skipDatabaseImage\u003e\n                \u003centando.engine.depends.on\u003e${project.artifactId}-dbms\u003c/entando.engine.depends.on\u003e\n                \u003cdb.base.image\u003eentando-postgresql95-base\u003c/db.base.image\u003e\n                \u003cdb.init.command\u003e$STI_SCRIPTS_PATH/init-postgresql-from-war.sh  --war-file=/tmp/${project.build.finalName}.war --jetty-version=${jetty.version}\n                \u003c/db.init.command\u003e\n                \u003cdb.volume.mount.path\u003e/var/lib/pgsql/data\u003c/db.volume.mount.path\u003e\n                \u003cdb.server.port\u003e5432\u003c/db.server.port\u003e\n\n\n                \u003cportdb.database\u003eportdb\u003c/portdb.database\u003e\n                \u003cportdb.url\u003ejdbc:postgresql://${docker.host.address}:${db.server.local.port}/${portdb.database}\u003c/portdb.url\u003e\n                \u003cportdb.username\u003eportdbuser\u003c/portdb.username\u003e\n                \u003cportdb.password\u003eportdb123\u003c/portdb.password\u003e\n                \u003cportdb.jndi\u003ejava:/jdbc/portDataSource\u003c/portdb.jndi\u003e\n                \u003cportdb.driverClassName\u003eorg.postgresql.Driver\u003c/portdb.driverClassName\u003e\n\n                \u003cservdb.database\u003eservdb\u003c/servdb.database\u003e\n                \u003cservdb.url\u003ejdbc:postgresql://${docker.host.address}:${db.server.local.port}/${servdb.database}\u003c/servdb.url\u003e\n                \u003cservdb.username\u003eservdbuser\u003c/servdb.username\u003e\n                \u003cservdb.password\u003eservdb123\u003c/servdb.password\u003e\n                \u003cservdb.jndi\u003ejava:/jdbc/servDataSource\u003c/servdb.jndi\u003e\n                \u003cservdb.driverClassName\u003eorg.postgresql.Driver\u003c/servdb.driverClassName\u003e\n\n                \u003c!-- No DB work required from the server image. Just set the build_id --\u003e\n                \u003cserver.init.command\u003eecho $(date +%s) \u003e /entando-data-templates/build_id\u003c/server.init.command\u003e\n\n                \u003c!--Hard coded ports for local development --\u003e\n                \u003cappbuilder.port\u003e5000\u003c/appbuilder.port\u003e\n                \u003cdb.server.local.port\u003e${db.server.port}\u003c/db.server.local.port\u003e\n                \u003centando.engine.port\u003e8080\u003c/entando.engine.port\u003e\n            \u003c/properties\u003e\n        \u003c/profile\u003e\n\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fentando%2Fentando-pam-app","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fentando%2Fentando-pam-app","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fentando%2Fentando-pam-app/lists"}