diff --git a/.woodpecker/main.yml b/.woodpecker/main.yml new file mode 100644 index 0000000..db68991 --- /dev/null +++ b/.woodpecker/main.yml @@ -0,0 +1,18 @@ +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: master + commands: + - rm -rfv /var/www/press/* + - cp -rv out/. /var/www/press + volumes: + - /var/www/press:/var/www/press diff --git a/Jenkinsfile b/Jenkinsfile deleted file mode 100644 index 8fb0b72..0000000 --- a/Jenkinsfile +++ /dev/null @@ -1,22 +0,0 @@ -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''' - } - } - } -}