Skip to content

Commit

Permalink
Use roda instead of sinatra
Browse files Browse the repository at this point in the history
  • Loading branch information
gl-johnson committed May 23, 2023
1 parent 49f27d5 commit 293fb2b
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 33 deletions.
3 changes: 1 addition & 2 deletions tests/integration/apps/ruby/Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@ source 'https://rubygems.org'

ruby '~> 3.2'

gem 'sinatra', ">= 2.2.0"
gem 'rack', ">= 2.2.4"

gem 'conjur-api'
gem 'conjur-cli'
gem 'thin'
gem 'roda'
30 changes: 10 additions & 20 deletions tests/integration/apps/ruby/Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ GEM
minitest (>= 5.1)
tzinfo (~> 2.0)
zeitwerk (~> 2.3)
addressable (2.8.1)
addressable (2.8.4)
public_suffix (>= 2.0.2, < 6.0)
concurrent-ruby (1.2.2)
conjur-api (5.4.0)
Expand All @@ -33,56 +33,46 @@ GEM
http-accept (1.7.0)
http-cookie (1.0.5)
domain_name (~> 0.5)
i18n (1.12.0)
i18n (1.13.0)
concurrent-ruby (~> 1.0)
mime-types (3.4.1)
mime-types-data (~> 3.2015)
mime-types-data (3.2023.0218.1)
minitest (5.18.0)
mustermann (3.0.0)
ruby2_keywords (~> 0.0.1)
netrc (0.11.0)
public_suffix (5.0.1)
rack (3.0.1)
rack-protection (3.0.5)
rack
rack (~> 3.0.1)
rest-client (2.1.0)
http-accept (>= 1.7.0, < 2.0)
http-cookie (>= 1.0.2, < 2.0)
mime-types (>= 1.16, < 4.0)
netrc (~> 0.8)
ruby2_keywords (0.0.5)
sinatra (3.0.5)
mustermann (~> 3.0)
rack (~> 3.0.1)
rack-protection (= 3.0.5)
tilt (~> 2.0)
roda (3.68.0)
rack
table_print (1.5.7)
thin (1.8.1)
thin (1.8.2)
daemons (~> 1.0, >= 1.0.9)
eventmachine (~> 1.0, >= 1.0.4)
rack (~> 3.0.1)
tilt (2.1.0)
rack (>= 1, < 3)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
unf (0.1.4)
unf_ext
unf_ext (0.0.8.2)
xdg (2.2.3)
zeitwerk (2.6.7)
zeitwerk (2.6.8)

PLATFORMS
x86_64-linux

DEPENDENCIES
conjur-api
conjur-cli
rack (>= 3.0.1)
sinatra (>= 2.2.0)
roda
thin

RUBY VERSION
ruby 3.2.1p31

BUNDLED WITH
2.4.11
2.4.10
20 changes: 9 additions & 11 deletions tests/integration/apps/ruby/test_app.rb
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
require 'sinatra/base'
require 'roda'

class TestApp < Sinatra::Application
class TestApp < Roda
plugin :default_headers, 'Content-Type'=>'text/html'

configure do
set :bind, '0.0.0.0'
end

get '/' do
"
route do |r|
r.root do
"
<h1>Visit us @ www.conjur.org!</h1>
<h3>Space-wide Secrets</h3>
<p>Database Username: #{ENV['SPACE_USERNAME']}</p>
<p>Database Password: #{ENV['SPACE_PASSWORD']}</p>
"
"
end
end

end
end

0 comments on commit 293fb2b

Please sign in to comment.