Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

patch: Provision flintlock from latest release #483

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,18 @@ The table below shows you which versions of Firecracker are compatible with Flin

| Flintlock | Firecracker |
| ----------------- | ------------------ |
| <= v0.1.0 | <= v0.25.2-macvtap |
| <= v0.1.0-alpha.6 | <= v0.25.2-macvtap |
| v0.1.0-alpha.7 | **Do not use** |
| v0.1.0-alpha.8 | <= v0.25.2-macvtap |

> Note: Flintlock currently requires a custom build of Firecracker available [here](https://github.com/weaveworks/firecracker/releases).
> Note: Flintlock currently requires a custom build of Firecracker available [here][fc-fork].

> Note: Due to upstream development issues, Flintlock in future will only support
Firecracker [`v0.25.2-macvtap`][fc-fork]. We will not maintain any versions beyond this.
In future releases of Flintlock, Cloud Hypervisor will be the default and recommended
MicroVM driver.

## License

[MPL-2.0 License][license]
Expand All @@ -68,3 +75,4 @@ The table below shows you which versions of Firecracker are compatible with Flin
[milestones]: https://github.com/weaveworks-liquidmetal/flintlock/milestones
[adr]: ./docs/adr
[license]: ./LICENSE
[fc-fork]: https://github.com/weaveworks/firecracker/releases
11 changes: 1 addition & 10 deletions hack/scripts/provision.sh
Original file line number Diff line number Diff line change
Expand Up @@ -196,15 +196,6 @@ latest_release_tag() {
echo "$url"
}

# Returns the tag associated with a "latest" pre-release (pre-releases do not show
# up in the API as used in the above latest_release_tag func)
latest_pre_release_tag() {
local repo_name="$1"
tag=$(git ls-remote --tags --sort="v:refname" "https://github.com/$repo_name" |
tail -n 1 | sed 's/.*\///; s/\^{}//')
echo "$tag"
}

# Install the untarred binary attached to a release to /usr/local/bin
install_release_bin() {
local download_url="$1"
Expand Down Expand Up @@ -295,7 +286,7 @@ install_flintlockd() {
say "Installing flintlockd version $tag to $INSTALL_PATH"

if [[ "$tag" == "$DEFAULT_VERSION" ]]; then
tag=$(latest_pre_release_tag "$FLINTLOCK_REPO")
tag=$(latest_release_tag "$FLINTLOCK_REPO")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need the latest_pre_release_tag function after this patch?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

technically no. i know i am usually ruthless when it comes to deleting dead code, but for some reason I had great attachment to this one 🤣

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's dead i killed it hope you are happy 😭 😭

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😱

fi

url=$(build_download_url "$FLINTLOCK_REPO" "$tag" "$FLINTLOCK_RELEASE_BIN")
Expand Down