---
title: "Deploy from an uploaded Docker image tarball"
method: POST
path: "/projects/{project_id}/environments/{environment_id}/deploy/image-upload"
tags: ["Deployments"]
---

# Deploy from an uploaded Docker image tarball

`POST /projects/{project_id}/environments/{environment_id}/deploy/image-upload`

## Request

- Base URL: `/api` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/api/projects/{project_id}/environments/{environment_id}/deploy/image-upload`
- Auth: HTTP bearer

Uploads a Docker image tarball (from `docker save`) and deploys it directly.
The image is imported using `docker load` and then deployed to the specified environment.
This is useful when you want to deploy an image without pushing to a registry first.

The uploaded file should be a tarball created by `docker save myimage:tag > image.tar`
or `docker save myimage:tag | gzip > image.tar.gz` (gzip compressed tarballs are also supported).

## Path parameters

- `project_id` integer, required
- `environment_id` integer, required

## Query parameters

- `tag` string, nullable
- `health_check_path` string, nullable
- `upload_request_id` string, nullable

## Response `202`

Image imported and deployment started

- RemoteDeploymentResponse
  - `created_at` string, date-time, required
  - `environment_id` integer, required
  - `id` integer, required
  - `project_id` integer, required
  - `slug` string, required
  - `source_type` string, required
  - `state` string, required

## Other responses

- `400`: Invalid request or unsupported format
- `401`: Unauthorized
- `403`: Insufficient permissions
- `404`: Project or environment not found
- `409`: Deployment method unavailable in stateless mode
- `413`: Image tarball too large
- `500`: Internal server error

## Changes

- **2026-10-05** `4b228ebed583`: 1 info
  - added the non-success response with the status `409`
- **2026-10-05** `63a80791dc58`: 1 info
  - removed the non-success response with the status `409`
- **2026-09-22** `1dd3766c34ed`: 1 info
  - added the non-success response with the status `409`
- **2026-09-16** `a378a436e715`: 1 info
  - added the new optional `query` request parameter `upload_request_id`
- **2026-07-01** `d83dcb738585`: 2 info
  - api tag `Deployments` added
  - added the new optional `query` request parameter `health_check_path`

[Operation history](https://skmtc.dev/gotempsh/apis/temps/changes/projects/:project_id/environments/:environment_id/deploy/image-upload/post.md)

---

[API](https://skmtc.dev/gotempsh/apis/temps.md) - [All operations](https://skmtc.dev/gotempsh/apis/temps/llms.txt) - [OpenAPI document](https://skmtc.dev/gotempsh/apis/temps/revisions/3b040526eb43?raw)
