diff options
author | Paul Cristian Sarbu <paul.cristian.sarbu@huawei.com> | 2024-07-26 16:08:56 +0200 |
---|---|---|
committer | Paul Cristian Sarbu <paul.cristian.sarbu@huawei.com> | 2024-07-30 12:10:06 +0200 |
commit | 507e944f8b40f30d8201af96ff3fe6778161abbb (patch) | |
tree | c2d7b29fad38688494f5bfb630810f34793dfa61 /src/buildtool/execution_api/execution_service/server_implementation.cpp | |
parent | 461ba224785cba270b37375d9dc25f06a630d723 (diff) | |
download | justbuild-507e944f8b40f30d8201af96ff3fe6778161abbb.tar.gz |
Pass RemoteContext to execution server
Diffstat (limited to 'src/buildtool/execution_api/execution_service/server_implementation.cpp')
-rw-r--r-- | src/buildtool/execution_api/execution_service/server_implementation.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/buildtool/execution_api/execution_service/server_implementation.cpp b/src/buildtool/execution_api/execution_service/server_implementation.cpp index 11be6309..43edd6aa 100644 --- a/src/buildtool/execution_api/execution_service/server_implementation.cpp +++ b/src/buildtool/execution_api/execution_service/server_implementation.cpp @@ -34,7 +34,6 @@ #include "src/buildtool/execution_api/execution_service/cas_server.hpp" #include "src/buildtool/execution_api/execution_service/execution_server.hpp" #include "src/buildtool/execution_api/execution_service/operations_server.hpp" -#include "src/buildtool/execution_api/remote/config.hpp" #include "src/buildtool/logging/log_level.hpp" #include "src/buildtool/logging/logger.hpp" @@ -82,6 +81,7 @@ auto ServerImpl::Create(std::optional<std::string> interface, } auto ServerImpl::Run(gsl::not_null<LocalContext const*> const& local_context, + gsl::not_null<RemoteContext const*> const& remote_context, ApiBundle const& apis, std::optional<std::uint8_t> op_exponent) -> bool { ExecutionServiceImpl es{local_context, &*apis.local, op_exponent}; @@ -102,7 +102,8 @@ auto ServerImpl::Run(gsl::not_null<LocalContext const*> const& local_context, // check authentication credentials; currently only TLS/SSL is supported std::shared_ptr<grpc::ServerCredentials> creds; - if (const auto* tls_auth = std::get_if<Auth::TLS>(&apis.auth.method); + if (const auto* tls_auth = + std::get_if<Auth::TLS>(&remote_context->auth->method); tls_auth != nullptr) { auto tls_opts = grpc::SslServerCredentialsOptions{}; |