<p>If I correct understand Your problem, You want to build app with diffrent ccs and images.</p>

<p>Jenkins suports maven and simplest way is to use maven profiles plus <a href="https://maven.apache.org/plugins/maven-war-plugin/examples/adding-filtering-webresources.html" rel="nofollow noreferrer">maven-war-plugin</a> 
eg.:</p>

<pre><code>&lt;build&gt;
&lt;plugins&gt;
    &lt;plugin&gt;
        &lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt;
        &lt;artifactId&gt;maven-war-plugin&lt;/artifactId&gt;
        &lt;configuration&gt;
            &lt;webResources&gt;
                &lt;webResource&gt;
                    &lt;directory&gt;src/main/profile/webapp/${images.folder}&lt;/directory&gt;
                    &lt;targetPath&gt;images&lt;/targetPath&gt;
                &lt;/webResource&gt;
            &lt;/webResources&gt;
        &lt;/configuration&gt;
    &lt;/plugin&gt;
&lt;/plugins&gt;
</code></pre>

<p></p>

<pre><code>&lt;profiles&gt;
&lt;profile&gt;
    &lt;id&gt;prod_client_1&lt;/id&gt;
    &lt;properties&gt;
        &lt;images.folder&gt;prod_client_1&lt;/images.folder&gt;
    &lt;/properties&gt;
&lt;/profile&gt;
&lt;profile&gt;
    &lt;id&gt;prod_client_2&lt;/id&gt;
    &lt;properties&gt;
        &lt;images.folder&gt;prod_client_2&lt;/images.folder&gt;
    &lt;/properties&gt;
&lt;/profile&gt;
</code></pre>

<p></p>

<p>For other resources filtering <a href="http://maven.apache.org/plugins/maven-resources-plugin/examples/include-exclude.html" rel="nofollow noreferrer">maven-resources-plugin</a></p>

<p>At least should be helpful this approach <a href="https://blog.sonatype.com/2008/04/how-to-share-resources-across-projects-in-maven/" rel="nofollow noreferrer">sharing resources across projects</a></p>

CC BY-SA 4.0
2018-06-29T13:03:12.877Z
That's pretty neat for a java application, what about other languages ?
Tensibai
CC BY-SA 4.0
2018-07-10T18:50:42.383Z
we also hava one static very simple web application that shares all images and css, across jee-web and php, you ca use docker via nginx
speedee
CC BY-SA 4.0
2018-07-10T19:05:47.940Z
How does this relate to your answer? I fail to see a link between maven plug-in and static CSS resources, mind editing your answer to complete?
Tensibai
CC BY-SA 3.0
2018-03-30T17:14:07.933Z
2018-03-30T17:14:07.933Z
speedee
<p>Looking for advice on how best to configure my workflow.</p>

<p>I have an application, that we currently customise for clients (white label) but our OLD devs have made the deployment of this very messy, multiple branches for each client. So merging is a nightmare and some clients are missing features etc.</p>

<p>The only difference between the clients version of our app, is some minor CSS changes and a couple of images.</p>

<p>We currently build with Jenkins and host with AWS Elastic Beanstalk.</p>

<p>What my question is, once we have merged and corrected the issues with the old developers. Am I able to trigger a single or multiple builds, from 1 branch and replace all the CSS values in my app and a couple of images? So we can just push to our master branch and build our production app and also all our clients white labels</p>

CC BY-SA 3.0
2018-03-24T23:38:44.373Z
I don't think I understand the question. You describe a "before" context, which you mentioned is being fixed, but without describing how. And you're asking how you can do something in the "after" context. Can you please clarify? Take out if the "before" context if it's not relevant (or mention how it is relevant) and describe the "after" context.
Dan Cornilescu
CC BY-SA 3.0
2018-04-30T07:46:47.073Z
If a customer specific logic is to have a configurable frontend, why not decouple it to a conglfiguration layer to have customer-specific e.g. Yaml files? Additionally, you might want to have a look on a generative CSS framework like Sass.
Ta Mu
CC BY-SA 4.0
2018-06-29T13:02:52.467Z
What language is your application in ? nodejs ? php ? java ? solution will differ depending on that
Tensibai
<jenkins><amazon-web-services>
Multiple builds from one branch but different CSS values
Bridgewater
# Multiple builds from one branch but different CSS values

(Asked by: username_0 on 2018-03-24)

Looking for advice on how best to configure my workflow.

I have an application, that we currently customise for clients (white label) but our OLD devs have made the deployment of this very messy, multiple branches for each client. So merging is a nightmare and some clients are missing features etc.

The only difference between the clients version of our app, is some minor CSS changes and a couple of images.

We currently build with Jenkins and host with AWS Elastic Beanstalk.

What my question is, once we have merged and corrected the issues with the old developers. Am I able to trigger a single or multiple builds, from 1 branch and replace all the CSS values in my app and a couple of images? So we can just push to our master branch and build our production app and also all our clients white labels

**Tags:** jenkins, amazon-web-services

> **Comments:**
> **username_1**: I don't think I understand the question. You describe a "before" context, which you mentioned is being fixed, but without describing how. And you're asking how you can do something in the "after" context. Can you please clarify? Take out if the "before" context if it's not relevant (or mention how it is relevant) and describe the "after" context.  
> **username_2**: If a customer specific logic is to have a configurable frontend, why not decouple it to a conglfiguration layer to have customer-specific e.g. Yaml files? Additionally, you might want to have a look on a generative CSS framework like Sass.  
> **username_3**: What language is your application in ? nodejs ? php ? java ? solution will differ depending on that  

---

## 1 answers

### Answer by username_4 on 2018-03-30. Score: 0

If I correct understand Your problem, You want to build app with diffrent ccs and images.
Jenkins suports maven and simplest way is to use maven profiles plus maven-war-plugin 
eg.:


    
        org.apache.maven.plugins
        maven-war-plugin
        
            
                
                    src/main/profile/webapp/${images.folder}
                    images
                
            
        
    





    prod_client_1
    
        prod_client_1
    


    prod_client_2
    
        prod_client_2
    



For other resources filtering maven-resources-plugin
At least should be helpful this approach sharing resources across projects

> **Comments:**
> **username_3**: That's pretty neat for a java application, what about other languages ?  
> **username_4**: we also hava one static very simple web application that shares all images and css, across jee-web and php, you ca use docker via nginx  
> **username_3**: How does this relate to your answer? I fail to see a link between maven plug-in and static CSS resources, mind editing your answer to complete?  

---

