Jooyung Han | 4df1a54 | 2021-06-09 14:17:32 +0900 | [diff] [blame^] | 1 | /* |
| 2 | * Copyright (C) 2021 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 | |
| 17 | syntax = "proto3"; |
| 18 | |
| 19 | package android.microdroid; |
| 20 | |
| 21 | // This .proto is for the schema of a VM payload config (JSON) |
| 22 | |
| 23 | message PayloadConfig { |
| 24 | uint32 version = 1; |
| 25 | |
| 26 | OsConfig os = 2; |
| 27 | |
| 28 | Task task = 3; |
| 29 | |
| 30 | repeated ApexConfig apexes = 4; |
| 31 | } |
| 32 | |
| 33 | message OsConfig { |
| 34 | // for now "microdroid" is the only type we support |
| 35 | string name = 1; |
| 36 | } |
| 37 | |
| 38 | message Task { |
| 39 | string command = 1; |
| 40 | repeated string args = 2; |
| 41 | } |
| 42 | |
| 43 | message ApexConfig { |
| 44 | string name = 1; |
| 45 | |
| 46 | // TODO(b/186396080) An APEX can be identified either by |
| 47 | // (1) its name |
| 48 | // (2) name and public key (or cert) |
| 49 | // or (3) name and exact hash. |
| 50 | // Rollback index should be supported for the case (2). |
| 51 | } |