| 1 |
# Copyright 2015 gRPC authors. |
| 2 |
# |
| 3 |
# Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 |
# you may not use this file except in compliance with the License. |
| 5 |
# You may obtain a copy of the License at |
| 6 |
# |
| 7 |
# http://www.apache.org/licenses/LICENSE-2.0 |
| 8 |
# |
| 9 |
# Unless required by applicable law or agreed to in writing, software |
| 10 |
# distributed under the License is distributed on an "AS IS" BASIS, |
| 11 |
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 |
# See the License for the specific language governing permissions and |
| 13 |
# limitations under the License. |
| 14 |
|
| 15 |
ssl_roots_path = File.expand_path('../../../../etc/roots.pem', __FILE__) |
| 16 |
|
| 17 |
require_relative 'grpc/errors' |
| 18 |
require_relative 'grpc/structs' |
| 19 |
require_relative 'grpc/grpc' |
| 20 |
require_relative 'grpc/logconfig' |
| 21 |
require_relative 'grpc/notifier' |
| 22 |
require_relative 'grpc/version' |
| 23 |
require_relative 'grpc/core/status_codes' |
| 24 |
require_relative 'grpc/core/time_consts' |
| 25 |
require_relative 'grpc/generic/active_call' |
| 26 |
require_relative 'grpc/generic/client_stub' |
| 27 |
require_relative 'grpc/generic/service' |
| 28 |
require_relative 'grpc/generic/rpc_server' |
| 29 |
require_relative 'grpc/generic/interceptors' |
| 30 |
|
| 31 |
begin |
| 32 |
file = File.open(ssl_roots_path) |
| 33 |
roots = file.read |
| 34 |
GRPC::Core::ChannelCredentials.set_default_roots_pem roots |
| 35 |
ensure |
| 36 |
file.close |
| 37 |
end |