Colin Powell 2 vuotta sitten
vanhempi
commit
56d8862e54
1 muutettua tiedostoa jossa 19 lisäystä ja 3 poistoa
  1. 19 3
      .drone.yml

+ 19 - 3
.drone.yml

@@ -1,12 +1,20 @@
 ---
 ##################
-# Publish        #
+# Build & Publish#
 ##################
 
 kind: pipeline
-name: publish
+name: build and publish
 
 steps:
+  - name: build
+    image: klakegg/hugo:alpine
+    commands:
+      - hugo -d /tmp/.build/public
+      - ls /tmp/.build/public
+    volumes:
+      - name: hugo
+        path: /tmp/.build/public
   - name: publish
     image: drillster/drone-rsync
     settings:
@@ -15,10 +23,18 @@ steps:
         from_secret: key
       hosts:
         - box.unbl.ink
-      source: ~/pubilc/
+      source: /tmp/.build/public
       target: /home/user-data/www/unbl.ink/
       secrets: [ key ]
+    commands:
+      - ls /tmp/.build/public
+    volumes:
+      - name: hugo
+        path: /tmp/.build/public
 volumes:
   - name: docker
     host:
       path: /var/run/docker.sock
+  - name: hugo
+    host:
+      path: /tmp/cache/drone/hugo