Skip to content

Commit

Permalink
Update release process for newer docs
Browse files Browse the repository at this point in the history
The process is pretty easy, just add a new line in RELEASES with the
version number. Once that git tag is available it will start to show
up on subsequent builds.

Signed-off-by: Patrick East <east.patrick@gmail.com>
  • Loading branch information
patrick-east committed Apr 27, 2019
1 parent 69fe783 commit 9228efb
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
6 changes: 6 additions & 0 deletions build/gen-release-patch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,15 @@ EOF
mv _CHANGELOG.md CHANGELOG.md
}

update_website() {
local releases_file="docs/website/RELEASES"
echo "v${VERSION}" | cat - ${releases_file} > temp && mv temp ${releases_file}
}

main() {
update_makefile
update_changelog
update_website
git --no-pager diff --no-color
}

Expand Down
14 changes: 11 additions & 3 deletions docs/devel/RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ Versioning involves maintaining the following files:

- **CHANGELOG.md** - this file contains a list of all the important changes in each release.
- **Makefile** - the Makefile contains a VERSION variable that defines the version of the project.
- **docs/config.toml*** - this file determines which version is displayed as latest
in the [documentation](https://openpolicyagent.org/docs) (using the `params.versions.latest`
variable)
- **docs/website/RELEASES*** - this file determines which versions of documentation are displayed
in the public [documentation](https://openpolicyagent.org/docs). __The first entry on the list is
considered to be the latest.__

The steps below explain how to update these files. In addition, the repository
should be tagged with the semantic version identifying the release.
Expand Down Expand Up @@ -105,8 +105,16 @@ CHANGELOG.md snippet and uploading the binaries from the build phase.
- Copy the changelog content into the message.
- Upload the binaries.


## Notes

- The openpolicyagent/opa Docker image is automatically built and published to
Docker Hub as part of the Travis-CI pipeline. There are no manual steps
involved here.
- The docs and website should update and be published automatically. If they are not you can
trigger one by a couple of methods:
- Login to Netlify (requires permission for the project) and manually trigger a build.
- Post to the build webhook via:
```bash
curl -X POST -d {} https://api.netlify.com/build_hooks/5cc3aa86495f22c7a368f1d2
```

0 comments on commit 9228efb

Please sign in to comment.