kythe.io@v0.0.68-0.20240422202219-7225dbc01741/kythe/proto/extraction_config.proto (about)

     1  /*
     2   * Copyright 2018 The Kythe Authors. All rights reserved.
     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 kythe.proto;
    20  
    21  option go_package = "kythe.io/kythe/proto/extraction_config_go_proto";
    22  
    23  // Represents configuration data necessary to construct an extraction image.
    24  // Dockerfile reference: https://docs.docker.com/engine/reference/builder/
    25  message ExtractionConfiguration {
    26    // A list of the required images to be included in
    27    // the composite extraction image.
    28    repeated Image required_image = 1;
    29    // A list of the custom docker RUN commands to be executed during construction
    30    // of the composite extraction image. These can be used to install required
    31    // SDKs which have no existing base image.
    32    repeated RunCommand run_command = 2;
    33    // A list of parameters to configure as the entry point for the image. This
    34    // is specific to build system images, only the last entry point in an image
    35    // will be observed.
    36    repeated string entry_point = 3;
    37  
    38    // Represents the information required for utilizing an image to be composed
    39    // into a composite extraction image. The data within this message will be
    40    // utilized as follows:
    41    // FROM <image_uri> as <image_name>
    42    // # repeated:
    43    // COPY <image_copy_artifact.source> <image_copy_artifact.dest>
    44    message Image {
    45      // the image's URI to be utilized in the docker FROM command.
    46      string uri = 1;
    47      // A human readable name for the image, should be unique within the
    48      // composite image and distinct from the uri.
    49      string name = 2;
    50      // A list of copy specs to be utilize in the docker COPY command.
    51      repeated CopySpec copy_spec = 3;
    52      // A list of environment variables to be setup in concert with this
    53      // image.
    54      repeated EnvVar env_var = 4;
    55    }
    56  
    57    // Represents information required for copying resources from images to
    58    // composite images.
    59    message CopySpec {
    60      // The path to the source resource to be copied.
    61      string source = 1;
    62      // The destination path for the resource on the composite image.
    63      // If not specified assumed same as source.
    64      string destination = 2;
    65    }
    66  
    67    // Represents an image's corresonding environment variable to be incorporated
    68    // into the composite image. The data within this message will be utilized as
    69    // follows: ENV <name> <value>
    70    message EnvVar {
    71      string name = 1;
    72      string value = 2;
    73    }
    74  
    75    // Represents an image's corresponding run command to be incorporated into the
    76    // composite image. The data within this message will be utilized as follows:
    77    // RUN <command> "<arg[0]>" "<arg[1]>" ...
    78    message RunCommand {
    79      string command = 1;
    80      repeated string arg = 2;
    81    }
    82  }