Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dockerpackage #7

Open
wants to merge 9 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
FROM node:4-alpine


WORKDIR /opt/frontend

COPY . .

RUN npm install

EXPOSE 8079

CMD npm start
29 changes: 29 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
pipeline {
agent any
stages {
stage('build') {
steps {
sh 'npm install'
}
}

stage('test') {
steps {
sh 'npm install'
sh 'npm test'
}
}

stage('package') {
steps {
sh 'npm install'
sh 'npm run package'
archiveArtifacts '**/distribution/*.zip'
}
}

}
tools {
nodejs 'NodesJS 4.8.6'
}
}
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Front-end application written in [Node.js](https://nodejs.org/en/) that puts tog

# Setting up Dev Env

Platform : Ubuntu 16.04
Platform : Ubuntu 18.04


### Common Setup
Expand Down
2 changes: 2 additions & 0 deletions Test.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Test pipeline
test2
8 changes: 8 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
version: "3.6"

services:
frontend:
build: .
image: cloudapsar/frontend
ports:
- 8079