Skip to content

Commit

Permalink
Try to move the env vars into pluginManagement
Browse files Browse the repository at this point in the history
  • Loading branch information
kabir committed Apr 25, 2024
1 parent 6696a55 commit 54b647d
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 14 deletions.
21 changes: 14 additions & 7 deletions ejb-txn-remote-call/client/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,16 @@
<groupId>org.wildfly.plugins</groupId>
<artifactId>wildfly-maven-plugin</artifactId>
<version>${version.plugin.wildfly}</version>
<configuration>
<!-- Env used when calling wildfly:start goal -->
<env>
<POSTGRESQL_DATABASE>test</POSTGRESQL_DATABASE>
<POSTGRESQL_JNDI>java:jboss/datasources/ejbJtaDs</POSTGRESQL_JNDI>
<POSTGRESQL_PASSWORD>${postgresqlUsername}</POSTGRESQL_PASSWORD>
<POSTGRESQL_USER>${postgresqlPassword}</POSTGRESQL_USER>
</env>
</configuration>

</plugin>
</plugins>
</pluginManagement>
Expand All @@ -215,13 +225,10 @@
<configuration>
<filename>client.war</filename>
<serverConfig>standalone.xml</serverConfig>
<!-- Env used when calling wildfly:start goal -->
<env>
<POSTGRESQL_DATABASE>test</POSTGRESQL_DATABASE>
<POSTGRESQL_JNDI>java:jboss/datasources/ejbJtaDs</POSTGRESQL_JNDI>
<POSTGRESQL_PASSWORD>${postgresqlUsername}</POSTGRESQL_PASSWORD>
<POSTGRESQL_USER>${postgresqlPassword}</POSTGRESQL_USER>
</env>
<!--
Note that the pluginManagement section for this plugin contains environment variables
which are needed to connect to the database when doing 'mvn wildfly:start'
-->
</configuration>
<executions>
<execution>
Expand Down
20 changes: 13 additions & 7 deletions ejb-txn-remote-call/server/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,15 @@
<groupId>org.wildfly.plugins</groupId>
<artifactId>wildfly-maven-plugin</artifactId>
<version>${version.plugin.wildfly}</version>
<configuration>
<!-- Env used when calling wildfly:start goal -->
<env>
<POSTGRESQL_DATABASE>test</POSTGRESQL_DATABASE>
<POSTGRESQL_JNDI>java:jboss/datasources/ejbJtaDs</POSTGRESQL_JNDI>
<POSTGRESQL_PASSWORD>${postgresqlUsername}</POSTGRESQL_PASSWORD>
<POSTGRESQL_USER>${postgresqlPassword}</POSTGRESQL_USER>
</env>
</configuration>
</plugin>
</plugins>
</pluginManagement>
Expand Down Expand Up @@ -201,13 +210,10 @@
<configuration>
<filename>server.war</filename>
<serverConfig>standalone-ha.xml</serverConfig>
<!-- Env used when calling wildfly:start goal -->
<env>
<POSTGRESQL_DATABASE>test</POSTGRESQL_DATABASE>
<POSTGRESQL_JNDI>java:jboss/datasources/ejbJtaDs</POSTGRESQL_JNDI>
<POSTGRESQL_PASSWORD>${postgresqlUsername}</POSTGRESQL_PASSWORD>
<POSTGRESQL_USER>${postgresqlPassword}</POSTGRESQL_USER>
</env>
<!--
Note that the pluginManagement section for this plugin contains environment variables
which are needed to connect to the database when doing 'mvn wildfly:start'
-->
</configuration>
<executions>
<execution>
Expand Down

0 comments on commit 54b647d

Please sign in to comment.