pub struct PodCreateInput {Show 33 fields
pub allowed_cuda_versions: Option<Vec<CudaVersion>>,
pub cloud_type: Option<CloudType>,
pub compute_type: Option<ComputeType>,
pub container_disk_in_gb: Option<i32>,
pub container_registry_auth_id: Option<String>,
pub country_codes: Option<Vec<String>>,
pub cpu_flavor_ids: Option<Vec<CpuFlavorId>>,
pub cpu_flavor_priority: Option<String>,
pub data_center_ids: Option<Vec<DataCenterId>>,
pub data_center_priority: Option<String>,
pub docker_entrypoint: Option<Vec<String>>,
pub docker_start_cmd: Option<Vec<String>>,
pub env: Option<EnvVars>,
pub global_networking: Option<bool>,
pub gpu_count: Option<i32>,
pub gpu_type_ids: Option<Vec<GpuTypeId>>,
pub gpu_type_priority: Option<String>,
pub image_name: Option<String>,
pub interruptible: Option<bool>,
pub locked: Option<bool>,
pub min_disk_bandwidth_m_bps: Option<f64>,
pub min_download_mbps: Option<f64>,
pub min_ram_per_gpu: Option<i32>,
pub min_upload_mbps: Option<f64>,
pub min_vcpu_per_gpu: Option<i32>,
pub name: Option<String>,
pub network_volume_id: Option<String>,
pub ports: Option<Vec<String>>,
pub support_public_ip: Option<bool>,
pub template_id: Option<String>,
pub vcpu_count: Option<i32>,
pub volume_in_gb: Option<i32>,
pub volume_mount_path: Option<String>,
}Expand description
Input parameters for creating a new Pod.
This struct contains all the configuration options available when creating a Pod, including compute specifications, networking, storage, and deployment preferences. Most fields are optional and will use RunPod defaults if not specified.
§Examples
use runpod_sdk::model::{PodCreateInput, ComputeType, CloudType};
let create_input = PodCreateInput {
name: Some("my-pod".to_string()),
image_name: Some("runpod/pytorch:latest".to_string()),
compute_type: Some(ComputeType::Gpu),
cloud_type: Some(CloudType::Secure),
..Default::default()
};Fields§
§allowed_cuda_versions: Option<Vec<CudaVersion>>If the created Pod is a GPU Pod, a list of acceptable CUDA versions. If not set, any CUDA version is acceptable.
cloud_type: Option<CloudType>Set to SECURE to create the Pod in Secure Cloud. Set to COMMUNITY
to create the Pod in Community Cloud.
compute_type: Option<ComputeType>Set to GPU to create a GPU Pod. Set to CPU to create a CPU Pod.
If set to CPU, the Pod will not have a GPU attached and GPU-related
properties will be ignored.
container_disk_in_gb: Option<i32>The amount of disk space, in gigabytes (GB), to allocate on the container disk. The data on the container disk is wiped when the Pod restarts.
container_registry_auth_id: Option<String>Registry credentials ID for private container registries.
country_codes: Option<Vec<String>>A list of country codes where the created Pod can be located. If not set, the Pod can be located in any country.
cpu_flavor_ids: Option<Vec<CpuFlavorId>>If the created Pod is a CPU Pod, a list of RunPod CPU flavors which can be attached to the Pod. The order determines the rental priority.
cpu_flavor_priority: Option<String>If the created Pod is a CPU Pod, set to availability to respond to
current CPU flavor availability. Set to custom to always try to rent
CPU flavors in the order specified in cpu_flavor_ids.
data_center_ids: Option<Vec<DataCenterId>>A list of RunPod data center IDs where the created Pod can be located.
data_center_priority: Option<String>Set to availability to respond to current machine availability.
Set to custom to always try to rent machines from data centers
in the order specified in data_center_ids.
docker_entrypoint: Option<Vec<String>>If specified, overrides the ENTRYPOINT for the Docker image. If empty, uses the ENTRYPOINT defined in the image.
docker_start_cmd: Option<Vec<String>>If specified, overrides the start CMD for the Docker image. If empty, uses the start CMD defined in the image.
env: Option<EnvVars>Environment variables for the Pod container.
global_networking: Option<bool>Set to true to enable global networking for the created Pod. Currently only available for On-Demand GPU Pods on some Secure Cloud data centers.
gpu_count: Option<i32>If the created Pod is a GPU Pod, the number of GPUs attached to the Pod.
gpu_type_ids: Option<Vec<GpuTypeId>>If the created Pod is a GPU Pod, a list of RunPod GPU types which can be attached to the Pod. The order determines the rental priority.
gpu_type_priority: Option<String>If the created Pod is a GPU Pod, set to availability to respond to
current GPU type availability. Set to custom to always try to rent
GPU types in the order specified in gpu_type_ids.
image_name: Option<String>The image tag for the container run on the created Pod.
interruptible: Option<bool>Set to true to create an interruptible or spot Pod. An interruptible Pod can be rented at a lower cost but can be stopped at any time to free up resources for another Pod.
locked: Option<bool>Set to true to lock the Pod. Locking a Pod disables stopping or resetting it.
min_disk_bandwidth_m_bps: Option<f64>The minimum disk bandwidth, in megabytes per second (MBps), for the created Pod.
min_download_mbps: Option<f64>The minimum download speed, in megabits per second (Mbps), for the created Pod.
min_ram_per_gpu: Option<i32>If the created Pod is a GPU Pod, the minimum amount of RAM, in gigabytes (GB), allocated to the Pod for each GPU attached.
min_upload_mbps: Option<f64>The minimum upload speed, in megabits per second (Mbps), for the created Pod.
min_vcpu_per_gpu: Option<i32>If the created Pod is a GPU Pod, the minimum number of virtual CPUs allocated to the Pod for each GPU attached.
name: Option<String>A user-defined name for the created Pod. The name does not need to be unique.
network_volume_id: Option<String>The unique string identifying the network volume to attach to the created Pod. If attached, a network volume replaces the Pod network volume.
ports: Option<Vec<String>>A list of ports exposed on the created Pod. Each port is formatted as
[port number]/[protocol]. Protocol can be either http or tcp.
support_public_ip: Option<bool>If the created Pod is on Community Cloud, set to true if you need the Pod to expose a public IP address. On Secure Cloud, the Pod will always have a public IP address.
template_id: Option<String>If the Pod is created with a template, the unique string identifying that template.
vcpu_count: Option<i32>If the created Pod is a CPU Pod, the number of vCPUs allocated to the Pod.
volume_in_gb: Option<i32>The amount of disk space, in gigabytes (GB), to allocate on the Pod volume. The data on the Pod volume is persisted across Pod restarts.
volume_mount_path: Option<String>The absolute path where the network volume will be mounted in the filesystem.
Trait Implementations§
Source§impl Clone for PodCreateInput
impl Clone for PodCreateInput
Source§fn clone(&self) -> PodCreateInput
fn clone(&self) -> PodCreateInput
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more