Skip to content
Open
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
2 changes: 1 addition & 1 deletion frameworks/rails/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ RUN bundle install --jobs=$(nproc)

COPY . .

EXPOSE 8080
EXPOSE 8080 8081

ENV THRUSTER_TARGET_PORT=8080
ENV THRUSTER_LOG_REQUESTS=false
Expand Down
5 changes: 4 additions & 1 deletion frameworks/rails/config/puma.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
thread_count = ENV.fetch('RAILS_MAX_THREADS', 4).to_i
threads thread_count, thread_count

port 8080
tls_cert_path = ENV.fetch('TLS_CERT', '/certs/server.crt')
tls_key_path = ENV.fetch('TLS_KEY', '/certs/server.key')
bind "tcp://0.0.0.0:8080"
bind "ssl://0.0.0.0:8081?cert=#{tls_cert_path}&key=#{tls_key_path}"

# Allow all HTTP methods so Rack middleware can return 405 instead of Puma returning 501
supported_http_methods :any
Expand Down
3 changes: 2 additions & 1 deletion frameworks/rails/meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,12 @@
"limited-conn",
"json",
"json-comp",
"json-tls",
"upload",
"api-4",
"api-16",
"async-db",
"static"
],
"maintainers": []
}
}
Loading