Skip to content

Commit

Permalink
test: fix example-buildpack
Browse files Browse the repository at this point in the history
It wasn't used and didn't work without updating dependencies.
  • Loading branch information
kzys committed Nov 27, 2024
1 parent 72b6a5b commit 2c18623
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 1 deletion.
9 changes: 9 additions & 0 deletions example-buildpack/Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,13 @@ source "https://rubygems.org"

git_source(:github) {|repo_name| "https://github.com/#{repo_name}" }

# "rack" must be explicitly specified.
# https://devcenter.heroku.com/articles/rack
gem "rack"

# While the doc above doesn't mention that, Ruby no longer have a HTTP server
# by default. Use puma since webrick is not actively maintained.
# https://bugs.ruby-lang.org/issues/17303
gem "puma"

gem "sinatra"
5 changes: 5 additions & 0 deletions example-buildpack/Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ GEM
specs:
mustermann (2.0.2)
ruby2_keywords (~> 0.0.1)
nio4r (2.7.4)
puma (6.5.0)
nio4r (~> 2.0)
rack (2.2.8.1)
rack-protection (2.2.3)
rack
Expand All @@ -18,6 +21,8 @@ PLATFORMS
ruby

DEPENDENCIES
puma
rack
sinatra

BUNDLED WITH
Expand Down
2 changes: 1 addition & 1 deletion example-buildpack/fly.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ app = "flyctl-example-buildpack"


[build]
builder = "heroku/buildpacks:20"
builder = "heroku/builder:24"

[deploy]
release_command = "sh release.sh"
Expand Down
5 changes: 5 additions & 0 deletions test/preflight/testlib/helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,11 @@ func otherRegionsFromEnv() []string {
}
}

func RepositoryRoot() string {
_, filename, _, _ := runtime.Caller(0)
return filepath.Join(path.Dir(filename), "../../..")
}

func currentRepoFlyctl() string {
_, filename, _, _ := runtime.Caller(0)
flyctlBin := path.Join(path.Dir(filename), "../../..", "bin", "flyctl")
Expand Down

0 comments on commit 2c18623

Please sign in to comment.