Skip to content

Commit a43c6b0

Browse files
committed
[rails] Enable json-tls test
1 parent 5e3b115 commit a43c6b0

3 files changed

Lines changed: 7 additions & 3 deletions

File tree

frameworks/rails/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ RUN bundle install --jobs=$(nproc)
2020

2121
COPY . .
2222

23-
EXPOSE 8080
23+
EXPOSE 8080 8081
2424

2525
ENV THRUSTER_TARGET_PORT=8080
2626
ENV THRUSTER_LOG_REQUESTS=false

frameworks/rails/config/puma.rb

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
thread_count = ENV.fetch('RAILS_MAX_THREADS', 4).to_i
22
threads thread_count, thread_count
33

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

69
# Allow all HTTP methods so Rack middleware can return 405 instead of Puma returning 501
710
supported_http_methods :any

frameworks/rails/meta.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,12 @@
1212
"limited-conn",
1313
"json",
1414
"json-comp",
15+
"json-tls",
1516
"upload",
1617
"api-4",
1718
"api-16",
1819
"async-db",
1920
"static"
2021
],
2122
"maintainers": []
22-
}
23+
}

0 commit comments

Comments
 (0)