|
1 | | -# Cache for Maven (.m2 repository) |
| 1 | +# |
| 2 | +# Backend |
| 3 | +# |
| 4 | + |
| 5 | +# Backend:: Cache for Maven (.m2 repository) |
2 | 6 | mavencache: |
3 | 7 | image: busybox |
4 | 8 | labels: |
5 | | - com.mgreau.wilfly.websocket: "Cache Maven" |
| 9 | + com.mgreau.docker4dev.backend.cache.maven: "Cache Maven" |
6 | 10 | volumes: |
7 | 11 | - ~/.m2:/root/.m2 |
8 | 12 |
|
9 | | -# Project Base |
| 13 | +# Backend:: Project CodeBase |
10 | 14 | mavenproject: |
11 | 15 | image: busybox |
12 | 16 | labels: |
13 | | - com.mgreau.wilfly.websocket: "Java sources" |
| 17 | + com.mgreau.docker4dev.backend.sources.javaee7: "Java sources" |
14 | 18 | volumes: |
15 | 19 | - .:/myproject |
16 | 20 |
|
| 21 | +# Backend:: Build project |
17 | 22 | mavenbuild: |
18 | 23 | image: vyolin/alpine-maven |
19 | 24 | labels: |
20 | | - com.mgreau.wilfly.websocket: "Build app" |
21 | | - command: mvn clean package -gs /root/.m2/settings.xml |
| 25 | + com.mgreau.docker4dev.backend.build.javaee7: "Build app" |
| 26 | + command: mvn clean package -gs /root/.m2/settings.xml -DfinalName=usopen |
22 | 27 | volumes_from: |
23 | 28 | - mavencache |
24 | 29 | - mavenproject |
25 | 30 | working_dir: /myproject |
26 | 31 | environment: |
27 | 32 | MAVEN_OPTS: -Xshare:auto -Xms128M -Xmx1G -XX:MaxPermSize=256M |
28 | 33 |
|
29 | | - |
| 34 | +# Backend:: Run Backend |
30 | 35 | wildflydeploy: |
31 | 36 | build: _docker/dev/appservers/. |
32 | 37 | labels: |
33 | 38 | com.mgreau.wilfly.websocket: "Deploy App" |
34 | 39 | ports: |
35 | 40 | - "8080:8080" |
36 | 41 | volumes: |
37 | | - - ./target:/opt/jboss/wildfly/standalone/deployments/ |
| 42 | + - ./target/usopen/:/opt/jboss/wildfly/standalone/deployments/ROOT.war/ |
| 43 | + |
| 44 | +# |
| 45 | +# Frontend |
| 46 | +# |
| 47 | +# Frontend:: Cache for Node (.node_modules repository) |
| 48 | +nodecache: |
| 49 | + image: busybox |
| 50 | + labels: |
| 51 | + com.mgreau.docker4dev.frontend.cache.node: "Cache Node dependencies" |
| 52 | + volumes: |
| 53 | + - ~/.node_modules:/root/.node_modules |
| 54 | + |
| 55 | +bowercache: |
| 56 | + image: busybox |
| 57 | + labels: |
| 58 | + com.mgreau.docker4dev.frontend.cache.bower: "Cache Bower dependencies" |
| 59 | + volumes: |
| 60 | + - ~/.bower_components:/root/.bower_components |
| 61 | + |
| 62 | +#To Build the frontend based on Angular and Material Design |
| 63 | +nodebuild: |
| 64 | + build: _docker/dev/builds/frontend/ |
| 65 | + command: npm config set cache /root/.node_modules --global && npm install && bower install --config.storage.cache=/root/.bower_components |
| 66 | + volumes: |
| 67 | + - ./frontend:/data |
| 68 | + volumes_from: |
| 69 | + - nodecache |
| 70 | + - bowercache |
| 71 | + environment: |
| 72 | + NODE_PATH: /root/.node_modules |
| 73 | + |
| 74 | +# Frontend:: Project CodeBase |
| 75 | +angularproject: |
| 76 | + image: busybox |
| 77 | + labels: |
| 78 | + com.mgreau.docker4dev.websocket: "Web sources" |
| 79 | + volumes: |
| 80 | + - .:/myproject |
0 commit comments