This section describes the steps to create deployment packages for your solution. Deployment packages are uploaded through Partner Portal, and are required for submitting your VM solution.
A deployment is a set of resources that are created and managed together—such as the resources needed for your solution. A deployment package or template is a specification for a set of resources that are typically deployed together, which streamlines the process of deploying that particular solution. Deployment Manager enables you to create deployment templates and packages for your VM solutions by using simple YAML, JSON, or ProtoText configuration files.
If your solution is a simple deployment of a single virtual machine instance with basic firewall rules, you can configure your deployment package directly in Partner Portal.
For most use cases, we recommend using the Deployment Manager
to generate Deployment Manager packages. With Deployment Manager Autogen, your
deployment package includes the following capabilities:
- Quota checks for CPUs and GPUs, so that users cannot deploy your solution if they exceed the quota requirements.
- Dynamic price updates in the Deployment Manager page.
- Support for shared VPCs.
- Prevents users from choosing machine types, GPUs, or subnetworks that are not available in the zone that they choose.
Before you begin
Install docker, so that you can build and run Autogen from the released Docker images.
If you would rather build Autogen from its source code, follow the steps in the Autogen GitHub repository.
Set up a command-line alias for Autogen.
To do this, enter the following:
alias autogen='docker run \ --rm \ --workdir /mounted \ --mount type=bind,source="$(pwd)",target=/mounted \ --user $(id -u):$(id -g) \ gcr.io/cloud-marketplace-tools/dm/autogen' autogen --help
Creating your Autogen configuration file
We recommend creating your initial configuration file by modifying the example
folder of the Autogen repository.
The comments inside the config file and the proto files ( autogen.proto, deployment_package_autogen_spec.proto and marketing_info.proto) contain information about the fields within, including which of them are required or optional. If you are generating a deployment package for a single solution, your config file should follow the specifications of the DeploymentPackageInput proto; if you are generating a deployment package for multiple solutions, your config file should follow the specifications of the BatchInput proto. Both of these specifications are found in autogen.proto.
To create your configuration file, change each of the fields of the example config file to reflect the configuration of your solution, and then run Autogen on your edited config file.
Other sample configurations are also available in the testdata folder.
Generating your deployment package
The following is a sample command that reads the spec in
example-config/solution.yaml and outputs a package to a folder called
mkdir solution_folder autogen \ --input_type YAML \ --single_input example-config/solution.yaml \ --output_type PACKAGE \ --output solution_folder
To run Autogen from the command line, you need to include one of the following
--single_input, if you're generating a package for one solution
--batch_input, if you're generating packages for multiple solutions
You can also use optional parameters like
specify which formats Autogen reads or writes. For information on all of the
possible options, see the
Once your deployment package has been created, you can compress the
solution_folder folder and then
upload that compressed file to Partner Portal.
Creating simple Deployment Manager packages in Partner Portal
Solutions that are simple deployments of single virtual machine instances with basic firewall rules can have their deployment packages configured directly in Partner Portal.
To configure this, open Partner Portal and select your solution from the list of solutions, then follow these steps:
- Next to Deployment Package, click Edit.
- Select to Generate a Package, and then click Continue.
- Select your VM image using the Project and Image dropdowns, and then click Continue.
- Select your Minimum machine type and Default machine type settings, then click Continue.
- Add any post-deployment next steps that your customers should take, and then click Continue.
- Set up your Firewall rules and other networking options if applicable, and then click Continue.
- You can choose to declare a site or admin URL. If your solution requires a login, you can set up login details when you submit your solution. Click Continue.
- Under List package contents, select the Operating System Name and OS Version of your VM image's operating system. You can then add a Name and Version for each additional piece of software that comes included as part of your solution. After you have listed all of your package's contents, click Continue.
- After you have completed the previous steps, your solution package is shown under Review. You can download the solution package, or click Edit JSON to manually modify it. Click Save to save the package and return to your solution.
For more complex deployments, you can create a deployment from scratch. If you're unsure about which type of solution is better for your project, talk to your Google Partner Engineer.
Deployment packages from the customer view
The following sections show the screen layouts that your customers see when they deploy your solution, for solutions based on auto-generated standard solution templates.
Customer view of deploying a package
The standard customer input elements are shown on the left side of the following screenshot and include zone, machine type, disk options, and networking options.
To deploy your solution, your customers must fill out the input fields, and then click Deploy.
Customer view of a deployed package
The following image shows you how your solution will appear to your customers after they have deployed it successfully.
The standard output elements are shown on the right side of the following screenshot and include site address, temporary admin password, and instance information.