Browse Source

drone

master
peter 5 years ago
parent
commit
94791b0f78
1 changed files with 10 additions and 30 deletions
  1. 10
    30
      .drone.yml

+ 10
- 30
.drone.yml View File

3
 
3
 
4
 steps:
4
 steps:
5
 
5
 
6
-- name: versioning
7
-  image: node:12
8
-  commands:
9
-  - echo $DRONE_BUILD_CREATED
10
-  - git config --global user.email "${DRONE_COMMIT_AUTHOR_EMAIL}"
11
-  - git config --global user.name "${DRONE_COMMIT_AUTHOR}"
12
-  - git add -f docs
13
-  - git commit -m "Drone tagged as ${DRONE_TAG}"
14
-  - git tag "${DRONE_TAG}"
15
-  - git push https://$GIT_USER:$GIT_PASSWORD@gitea.frontblock.me/fw-docs/${DRONE_REPO_NAME}.git master ${DRONE_TAG}
16
-
17
-  environment:
18
-    GIT_USER:
19
-      from_secret: git_user
20
-    GIT_PASSWORD:
21
-      from_secret: git_password
22
-  trigger:
23
-  event:
24
-    exclude:
25
-    - tag
26
-
27
 - name: restore cache
6
 - name: restore cache
28
   image: drillster/drone-volume-cache
7
   image: drillster/drone-volume-cache
29
   settings:
8
   settings:
79
     event:
58
     event:
80
       - tag
59
       - tag
81
 
60
 
82
-- name: commit documentation
61
+- name: deploy documentation
83
   image: node:12
62
   image: node:12
84
   commands:
63
   commands:
85
-  - git config --global user.email "frontwork.me@gmail.com"
86
-  - git config --global user.name "drone"
64
+  - echo $DRONE_BUILD_CREATED
65
+  - git config --global user.email "${DRONE_COMMIT_AUTHOR_EMAIL}"
66
+  - git config --global user.name "${DRONE_COMMIT_AUTHOR}"
87
   - git add -f docs
67
   - git add -f docs
88
-  - git commit --allow-empty -m "documented version at ${DRONE_BUILD_CREATED}"
89
-  - git tag ${DRONE_BUILD_CREATED}
90
-  - git status
91
-  - git push https://$GIT_USER:$GIT_PASSWORD@gitea.frontblock.me/fw-vendor/${DRONE_REPO_NAME}.git master ${DRONE_BUILD_CREATED}
68
+  - git commit -m "Drone tagged as ${DRONE_TAG}"
69
+  - git tag "${DRONE_TAG}"
70
+  - git push https://$GIT_USER:$GIT_PASSWORD@gitea.frontblock.me/fw-docs/${DRONE_REPO_NAME}.git master ${DRONE_TAG}
71
+
92
   environment:
72
   environment:
93
     GIT_USER:
73
     GIT_USER:
94
       from_secret: git_user
74
       from_secret: git_user
96
       from_secret: git_password
76
       from_secret: git_password
97
   trigger:
77
   trigger:
98
   event:
78
   event:
99
-  - tag
100
-  
79
+    - tag
80
+
101
 volumes:
81
 volumes:
102
 - name: cache 
82
 - name: cache 
103
   host:
83
   host:

Loading…
Cancel
Save