feat: add drone config
All checks were successful
continuous-integration/drone Build is passing

This commit is contained in:
Kazhnuz 2024-10-12 21:54:45 +02:00
parent 6023f8a7cc
commit 222dbd6da1
2 changed files with 34 additions and 1 deletions

32
.drone.yml Normal file
View file

@ -0,0 +1,32 @@
kind: pipeline
name: production
when:
event: [ push ]
branch: [ master ]
clone:
git:
image: plugins/git
pull: true
steps:
- name: build
image: node:latest
commands:
- npm i
- npm run compile
- name: deploy
image: drillster/drone-rsync
settings:
hosts:
from_secret: deploy_host
target: /var/www/moineau.kazhnuz.space
source: dist/*
user:
from_secret: deploy_user
key:
from_secret: deploy_key
when:
branch: master
delete: true

View file

@ -10,7 +10,8 @@
"minify-no-source-map": "sass --watch --no-source-map scss/moineau.scss --style compressed dist/css/moineau.min.css",
"build": "sass scss/moineau.scss dist/css/moineau.css && sass scss/moineau.scss --style compressed dist/css/moineau.min.css",
"serve": "http-server ./dist & npm run site & npm run minify",
"site": "cp data/cat.jpg dist/cat.jpg & node generate.js"
"site": "cp data/cat.jpg dist/cat.jpg & node generate.js",
"compile": "sass scss/moineau.scss --style compressed dist/css/moineau.min.css && npm run site"
},
"repository": {
"type": "git",