forked from digitalocean/csi-digitalocean
-
Notifications
You must be signed in to change notification settings - Fork 0
60 lines (51 loc) · 2.15 KB
/
release.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# Copyright 2022 DigitalOcean
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
### Release a new CSI version once a tag is pushed.
name: release
env:
DOCKER_ORG: digitalocean
DOCKER_USER: ${{ secrets.DockerHubUser }}
on:
push:
tags-ignore:
# The tags below are for Kubernetes <1.14 which are not supported by the
# upstream end-to-end tests and are not actively maintained anymore.
- v0.*
- v1.0.*
jobs:
release:
runs-on: ubuntu-20.04
steps:
- name: checkout
uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
with:
fetch-depth: 1
- name: Log into container registry
run: echo "${{ secrets.DockerHubToken }}" | docker login --username ${DOCKER_USER} --password-stdin
# Rebuild plugin instead of just promoting the latest :master image so
# that the right version is correctly baked into the release via the -X
# flag.
- name: Build and push released plugin image
run: |
VERSION="$(git describe --tags)"
DOCKER_REPO=${DOCKER_ORG}/do-csi-plugin make publish
- name: create Github release
uses: softprops/action-gh-release@b7e450da2a4b4cb4bfbae528f788167786cfcedf # v0.1.5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
body: |
See the [change log](CHANGELOG.md) for release details.
Refer to the [installation instructions](README.md#installing-to-kubernetes) to learn how the CSI driver can be installed. (**Note:** The driver comes pre-installed already for [DOKS](https://www.digitalocean.com/products/kubernetes/) users.)
draft: false