Skip to content

Latest commit

 

History

History
89 lines (58 loc) · 3.31 KB

RELEASEINST.md

File metadata and controls

89 lines (58 loc) · 3.31 KB

Release Instructions

The current release infrastructure is built into the project's Makefile. You'll need both curl and jq installed to upload releases onto GitHub.

To communicate with the GitHub releases API you'll need a personal access token. It's recommended you name it "Nakama Release Uploads" and store it in a file called .GITHUB_TOKEN.

New releases

To generate a new release with cross-compiled builds for all supported target architectures run make release. You can find the build output in "build/release/${version}/nakama-${platform}-${arch}".

build/release/${version}/
├── nakama-darwin-amd64
│   ├── CHANGELOG.md
│   ├── LICENSE
│   ├── README.md
│   └── nakama
├── nakama-${version}-darwin-amd64.tar.gz
...etc

Upload a release

A release can only be uploaded with the correct personal access token permissions on GitHub and write permissions on the repository.

To upload a release run make relupload TOKEN= TAG= where TOKEN is your personal access token and TAG is the tag which has already been created on GitHub.

make relupload TOKEN="0aaa00119084689a7721a40951aa54a354aaa000" TAG="v0.10.0"

Note This will upload all platforms/arch to a draft release on GitHub.

Full release workflow

The development team use these steps to build and upload a release.

  1. Update the CHANGELOG.md.

    Make sure to add the relevant Added, Changed, Deprecated, Removed, Fixed, and Security sections as suggested by keep a changelog.

  2. Update version in Makefile and commit. i.e. VERSION := 0.10.0-dev should become VERSION := 0.10.0.

    git add Makefile CHANGELOG.md
    git commit -m "Nakama 0.10.0 release."
    
  3. Tag the release.

    Note In source control good semver suggests a "v" prefix on a version. It helps group release tags.

    git tag -a v0.10.0 -m "v0.10.0"
    git push origin v0.10.0
    
  4. Upload the release.

    make relupload TOKEN="gh personal access token" TAG="v0.10.0"
    
  5. Login and access the new draft release on GitHub. Repeat the changelog in the release description. Then publish the release.

  6. Create Docker image and push to Docker Hub.

docker login
make docker dockerpush
  1. Add new ## [Unreleased] section to start of CHANGELOG.md. Increment and add suffix "-dev" to version in Makefile and commit. i.e. VERSION := 0.10.0 should now become VERSION := 0.11.0-dev.

    git add Makefile CHANGELOG.md
    git commit -m "Set new development version."
    git push origin master
    

Package Managers

Homebrew

The Homebrew package manager for macOS is supported by our releases. The script is maintained in the repository at "install/local/nakama.rb". This file is updated after a new release as needed.

Chocolatey

The Chocolatey package manager for Windows is supported by our releases. The scripts are maintained in the repository at "install/local/chocolatey/". These files are updated after a new release as needed.