Skip to content

Commit

Permalink
Add RELEASE documentation
Browse files Browse the repository at this point in the history
Closes: vmware#2368
Signed-off-by: Michael Gasch <[email protected]>
  • Loading branch information
Michael Gasch committed Apr 21, 2021
1 parent 899b900 commit a32cd0b
Show file tree
Hide file tree
Showing 3 changed files with 60 additions and 0 deletions.
56 changes: 56 additions & 0 deletions RELEASE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# How to create a new `govmomi` Release on Github

On every new tag matching `v*` pushed to the repository a Github Action Release
Workflow is executed.

The Github Actions release [workflow](.github/workflows/govmomi-release.yaml)
uses [`goreleaser`](http://goreleaser.com/) ([configuration
file](.goreleaser.yml)) and automatically creates/pushes:

- Release artifacts for `govc` and `vcsim` to the
[release](https://github.com/vmware/govmomi/releases) page, including
`LICENSE.txt`, `README` and `CHANGELOG`
- Docker images for `vmware/govc` and `vmware/vcsim` to Docker Hub
- Source code

## Verify `master` branch is up to date with the remote

```console
$ git checkout master
$ git fetch -avp
$ git diff master origin/master

# if your local and remote branches diverge run
$ git pull origin/master
```

⚠️ **Note:** These steps assume `origin` to point to the remote
`https://github.com/vmware/govmomi`, respectively
`[email protected]:vmware/govmomi`.

## Create the new Version Tag


Create a new release tag adhering to the [semantic
versioning](https://semver.org/) scheme:

```console
# Example
TAG=v0.25.0
git tag -a ${TAG} -m "Release ${TAG}"
```

## Push the new Tag

```console
# Will trigger Github Actions Release Workflow
git push origin refs/tags/${TAG}
```

## Verify Github Action Release Workflow

After pushing a new release tag, the status of the
workflow can be inspected
[here](https://github.com/vmware/govmomi/actions/workflows/govmomi-release.yaml).

![Release](static/release-workflow.png "Successful Release Run")
4 changes: 4 additions & 0 deletions govc/release.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
#!/bin/bash -e

# DEPRECATED!!!!
# Github Actions is creating releases from 0.25.0 onwards.
# TODO (@embano1): remove this file once #2369 lands

# To release govc:
# - Bump Version version var in flags/version.go
# - Update ../CHANGELOG.md and ./CHANGELOG.md
Expand Down
Binary file added static/release-workflow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit a32cd0b

Please sign in to comment.