forked from eclipse-che/che
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use docker to build dashboard app. (as alternative) (eclipse-che#5848)
* Use docker to build dashboard app. By using layer for package.json and bower.json file, it saves extra time to get npm or bower dependencies Also, if dashboard files are not modified, the build is faster. it targets as well 5127 By default : "$ mvn clean install" --> use docker "$ mvn clean install -Pnative" --> use native tools Change-Id: Ia65161b58e8ae70f7799500750a3d87687e34819 Signed-off-by: Florent BENOIT <fbenoit@redhat.com>
- Loading branch information
Showing
5 changed files
with
196 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
Dockerfile | ||
node_modules | ||
bower_components | ||
target | ||
pom.xml | ||
./typings | ||
./tmp | ||
./codeverage | ||
|
||
# Eclipse # | ||
################### | ||
|
||
*.launch | ||
.classpath | ||
.project | ||
.settings/ | ||
bin/ | ||
test-output/ | ||
maven-eclipse.xml | ||
|
||
# Idea # | ||
################## | ||
*.iml | ||
*.ipr | ||
*.iws | ||
.idea/ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# Copyright (c) 2012-2017 Red Hat, Inc | ||
# All rights reserved. This program and the accompanying materials | ||
# are made available under the terms of the Eclipse Public License v1.0 | ||
# which accompanies this distribution, and is available at | ||
# http://www.eclipse.org/legal/epl-v10.html | ||
|
||
# This is a Dockerfile allowing to build dashboard by using a docker container. | ||
# Build step: $ docker build -t eclipse-che-dashboard | ||
# It builds an archive file that can be used by doing later | ||
# $ docker run --rm eclipse-che-dashboard | tar -C target/ -zxf - | ||
FROM mhart/alpine-node:6 | ||
|
||
RUN apk update && \ | ||
apk add --no-cache git | ||
COPY package.json /dashboard/ | ||
RUN cd /dashboard && npm install | ||
COPY bower.json /dashboard/ | ||
RUN cd /dashboard && ./node_modules/.bin/bower install --allow-root | ||
COPY . /dashboard/ | ||
RUN cd /dashboard && npm run build && cd target/ && tar zcf /tmp/dashboard.tar.gz dist/ | ||
|
||
CMD zcat /tmp/dashboard.tar.gz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters