Compare commits
No commits in common. "5fb48b0fd77338a7a7c23565115df3500aee70a9" and "ef11e3a81435596ce6fa4fafd44f27d3d77dcfc3" have entirely different histories.
5fb48b0fd7
...
ef11e3a814
2 changed files with 22 additions and 18 deletions
|
@ -1,18 +0,0 @@
|
||||||
steps:
|
|
||||||
build:
|
|
||||||
image: node:latest
|
|
||||||
commands:
|
|
||||||
- cd src
|
|
||||||
- npm install
|
|
||||||
- npx presskit build --output ../out --pretty-links --collapse-menu --clean-build-folder
|
|
||||||
- cp .htaccess ../out
|
|
||||||
deploy:
|
|
||||||
image: debian:latest
|
|
||||||
when:
|
|
||||||
- event: [push, manual]
|
|
||||||
branch: main
|
|
||||||
commands:
|
|
||||||
- rm -rfv /var/www/press/*
|
|
||||||
- cp -rv out/. /var/www/press
|
|
||||||
volumes:
|
|
||||||
- /var/www/press:/var/www/press
|
|
22
Jenkinsfile
vendored
Normal file
22
Jenkinsfile
vendored
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
pipeline {
|
||||||
|
agent { label 'web' }
|
||||||
|
stages {
|
||||||
|
stage('Build') {
|
||||||
|
steps {
|
||||||
|
sh '''cd src
|
||||||
|
npm install
|
||||||
|
npx presskit build --output ../out --pretty-links --collapse-menu --clean-build-folder
|
||||||
|
cp .htaccess ../out'''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('Publish') {
|
||||||
|
when {
|
||||||
|
branch 'main'
|
||||||
|
}
|
||||||
|
steps {
|
||||||
|
sh '''rm -rf /var/www/press/*
|
||||||
|
cp -r out/. /var/www/press'''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue