maj drone to build image

main
greg 1 year ago
parent c72752d3ac
commit acf5cb3186
  1. 81
      .drone.yml

@ -1,6 +1,7 @@
kind: pipeline kind: pipeline
name: hugo name: hugo
type: docker type: docker
platform: platform:
os: linux os: linux
arch: arm64 arch: arm64
@ -12,45 +13,59 @@ trigger:
steps: steps:
####### DOCKER BUILD AND PUSH TO REGISTRY ######## ####### DOCKER BUILD AND PUSH TO REGISTRY ########
# - name: build docker image and push to registry - name: build docker image and push to registry
# image: plugins/docker image: plugins/docker
# volumes: volumes:
# - name: appsource - name: appsource
# path: "/src" path: "/src"
# - name: dockersock - name: dockersock
# path: "/var/run/docker.sock" path: "/var/run/docker.sock"
settings:
debug: true
username:
from_secret: REGISTRY_USER
password:
from_secret: REGISTRY_PASSWORD
registry: "dockerregistry.gregandev.fr"
insecure: true
privileged: true
repo: "dockerregistry.gregandev.fr/terminal-cv"
dockerfile: ./Dockerfile
# - name: docker
# image: thegeeklab/drone-docker-buildx:23
# privileged: true
# insecure: true
# settings: # settings:
# debug: true # registry: dockerregistry.gregandev.fr
# username: # username:
# from_secret: REGISTRY_USER # from_secret: REGISTRY_USER
# password: # password:
# from_secret: REGISTRY_PASSWORD # from_secret: REGISTRY_PASSWORDs
# registry: "dockerregistry.gregandev.fr" # repo: dockerregistry.gregandev.fr/terminal/cv
# insecure: true # tags: latest
# privileged: true # platform: linux/arm64
# repo: "greglebreton/terminal-cv"
# dockerfile: ./Dockerfile
######## NPM BROKEN ######## ######## NPM BROKEN ########
- name: install npm dependancies # - name: install npm dependancies
image: node # image: node
commands: # commands:
- npm install # - npm install
- npm audit fix # - npm audit fix
- npm run build # - npm run build
- name: deploy on server # - name: deploy on server
image: drillster/drone-rsync # image: drillster/drone-rsync
settings: # settings:
hosts: ["192.168.1.101"] # hosts: ["192.168.1.101"]
target: /workspace/terminal-cv/site # target: /workspace/terminal-cv/site
source: ./dist/* # source: ./dist/*
port: 2021 # port: 2021
user: # user:
from_secret: RSYNC_USER # from_secret: RSYNC_USER
key: # key:
from_secret: RSYNC_STACK_KEY # from_secret: RSYNC_STACK_KEY
######## TELEGRAM NOTIFICATION ######## ######## TELEGRAM NOTIFICATION ########

Loading…
Cancel
Save