• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 //
2 // Copyright (C) 2019 The Android Open Source Project
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 //      http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 
16 #pragma once
17 
18 #include <string>
19 #include <vector>
20 
21 #include "common/libs/fs/shared_fd.h"
22 #include "common/libs/utils/subprocess.h"
23 #include "host/libs/config/cuttlefish_config.h"
24 
25 namespace cuttlefish {
26 
27 struct KernelLogMonitorData {
28   std::vector<SharedFD> pipes;
29   std::vector<Command> commands;
30 };
31 
32 KernelLogMonitorData LaunchKernelLogMonitor(const CuttlefishConfig& config,
33                                             unsigned int number_of_event_pipes);
34 std::vector<Command> LaunchAdbConnectorIfEnabled(
35     const CuttlefishConfig& config);
36 std::vector<Command> LaunchSocketVsockProxyIfEnabled(
37     const CuttlefishConfig& config, SharedFD adbd_events_pipe);
38 std::vector<Command> LaunchModemSimulatorIfEnabled(
39     const CuttlefishConfig& config);
40 
41 std::vector<Command> LaunchVNCServer(const CuttlefishConfig& config);
42 
43 std::vector<Command> LaunchTombstoneReceiver(const CuttlefishConfig& config);
44 std::vector<Command> LaunchRootCanal(const CuttlefishConfig& config);
45 std::vector<Command> LaunchLogcatReceiver(const CuttlefishConfig& config);
46 std::vector<Command> LaunchConfigServer(const CuttlefishConfig& config);
47 
48 std::vector<Command> LaunchWebRTC(const CuttlefishConfig& config,
49                                   SharedFD kernel_log_events_pipe);
50 
51 std::vector<Command> LaunchMetrics();
52 
53 std::vector<Command> LaunchGnssGrpcProxyServerIfEnabled(
54     const CuttlefishConfig& config);
55 
56 std::vector<Command> LaunchSecureEnvironment(const CuttlefishConfig& config);
57 
58 std::vector<Command> LaunchBluetoothConnector(const CuttlefishConfig& config);
59 std::vector<Command> LaunchVehicleHalServerIfEnabled(
60     const CuttlefishConfig& config);
61 
62 std::vector<Command> LaunchConsoleForwarderIfEnabled(
63     const CuttlefishConfig& config);
64 
65 } // namespace cuttlefish
66