Skip to content
This repository has been archived by the owner on May 10, 2024. It is now read-only.

mule-domain-maven-plugin ignores the use of maven profiles #11

Open
jrichardsz opened this issue Mar 13, 2016 · 0 comments
Open

mule-domain-maven-plugin ignores the use of maven profiles #11

jrichardsz opened this issue Mar 13, 2016 · 0 comments

Comments

@jrichardsz
Copy link

I have a maven profile configuration that works fine for any java maven project. I use this configuration for my mule projects:

<project ...>

    <modelVersion>
    <groupId>
    <artifactId>
    <version>
    <packaging>

    <build>
        <finalName>${project.artifactId}</finalName>
        <resources>
            <resource>
                <directory>src/main/resources/${resource.dir}</directory>
                <filtering>true</filtering>
            </resource>
            <resource>
                <directory>src/main/resources</directory>
                <excludes>
                    <exclude>env1/</exclude>
                    <exclude>env2/</exclude>
                    ...
                </excludes>
                <filtering>false</filtering>
            </resource>
        </resources>
    </build>

    <profiles>
        <profile>
            <id>env1</id>
            <activation>
                <property>
                    <name>target.env1</name>
                    <value>env1</value>
                </property>
            </activation>
            <properties>
                <resource.dir>env1</resource.dir>
            </properties>
        </profile>
        <profile>
            <id>env2</id>
            <activation>
                <property>
                    <name>target.env2</name>
                    <value>env2</value>
                </property>
            </activation>
            <properties>
                <resource.dir>env2</resource.dir>
            </properties>
        </profile>
        <profile> ...
    </profiles>

</project>

But when I tried with mule domain project does not work. Result of maven execution has all folder with all properties environments.
As a summary , plugin ignores profiles in maven.
More explanation :

http://stackoverflow.com/questions/35930022/how-use-maven-profiles-in-mule-domain-project

Example of mule domain project :

https://github.com/jrichardsz/mule-esb-usefull-templates/tree/master/my_mule_domain_project

Thanks.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant