Added Jenkinsfile 15
This commit is contained in:
@@ -1,11 +1,15 @@
|
||||
FROM node:15-alpine
|
||||
|
||||
WORKDIR /app
|
||||
ENV NODE_ENV=production
|
||||
|
||||
COPY ./public /app/public
|
||||
COPY ./views /app/views
|
||||
COPY ./dist /app/views
|
||||
COPY ./dist /app/dist
|
||||
COPY ./package.json /app/package.json
|
||||
COPY ./package-lock.json /app/package-lock.json
|
||||
|
||||
RUN npm install
|
||||
|
||||
ENTRYPOINT npm start
|
||||
EXPOSE 3000
|
||||
2
Jenkinsfile
vendored
2
Jenkinsfile
vendored
@@ -97,7 +97,7 @@ node {
|
||||
sh 'npm prune'
|
||||
sh 'rm node_modules -rf'
|
||||
sh "docker rmi ${env.DOCKER_NAME} ${DOCKER_REGISTRY}/${env.DOCKER_NAME}"
|
||||
sh 'docker image prune'
|
||||
sh 'docker image prune -f'
|
||||
sh 'docker rmi $(docker images -a | grep "<none>" | awk "{print \$3}") &2>/del/null || exit 0'
|
||||
|
||||
/*mail body: 'project build successful',
|
||||
|
||||
Reference in New Issue
Block a user