Update An Image
Updates an existing image. You can modify various properties of the image such as name, version, operating system, and type-specific settings. The command validates that you're not trying to change the image type (Docker to Steam or vice versa) and ensures type-specific options match the current image type.
You cannot change the type of an image (from Docker to Steam or vice versa). If you need to change the image type, create a new image instead.
Usage
odin fleet images update --image-id=IMAGE_ID [--name=IMAGE_NAME] [--version=IMAGE_VERSION]
[--os=IMAGE_OS] [--docker-image=DOCKER_IMAGE] [--registry-id=REGISTRY_ID]
[--steam-app-id=STEAM_APP_ID] [--branch=STEAM_BRANCH] [--password=STEAM_PASSWORD]
[--command=STEAM_COMMAND] [--steamcmd-username=STEAMCMD_USERNAME]
[--steamcmd-password=STEAMCMD_PASSWORD] [--runtime=STEAM_RUNTIME] [--headful] [--request-license]
[--unpublished] [--additional-packages=PACKAGES] [--payload=JSON_PAYLOAD] [--dry-run]
Flags
The command will only update the fields that are provided. If you want to update multiple fields, you can provide them
all in one command. At least one update option must be supplied (besides --image-id).
-
--image-id=<number>: The ID of the image to update. This is a required option. -
--dry-run: An optional flag that shows the JSON payload that would be sent to the API without actually updating the image. You can use this to preview changes before applying them. -
--payload=<string>: An optional flag that allows you to specify a JSON payload to update the image. This is useful for non-interactive mode and if you want to update an image with a specific configuration.
Instead of providing a JSON payload, you can use the following options to update an image:
-
--name=<string>: The name of the image. -
--version=<string>: Specifies the version of the image. -
--os=<string>: Defines the operating system that the image is based on. Valid values arelinuxorwindows.
These options can be used to update a Docker image:
-
--docker-image=<string>: The name of the Docker image to use. This should be the full path to the Docker image in the registry. -
--registry-id=<number>: The ID of the Docker registry where the image is stored.
These options can be used to update a Steam image:
-
--steam-app-id=<number>: The Steam App ID associated with the image. -
--branch=<string>: Specifies the Steam branch to use (e.g.,beta,stable). -
--password=<string>: The password associated with the Steam branch, if required. -
--command=<string>: Specifies a command to be run by Steam. -
--steamcmd-username=<string>: The username for SteamCMD. -
--steamcmd-password=<string>: The password for SteamCMD. -
--runtime=<string>: Specifies the Steam runtime environment. -
--headful: An optional flag that enables Steam in headful mode. -
--request-license: An optional flag to request a Steam license. -
--unpublished: If your Steam app is not published, you need to set this flag. -
--additional-packages=<string>: Additional packages to install with the image.
Examples
Update the name and version of an image:
Update the Docker image reference:
Update multiple Steam-specific settings at once:
Preview changes without applying them using dry-run:
Global Flags
The following flags can be used with any ODIN CLI command:
-
--api-key=<string>The API key to use for authentication. If omitted, the CLI will use the api-key stored in the configuration file on your system. Use odin login to store the API key for subsequent commands. -
--app-id=<string>The ID of the app to use for the command. If omitted, the CLI will use the currently selected app. Use odin apps select to select an app interactively. -
--format=<string>The output format to use for the command. Supported formats arejson,value,flattenedandtable. If omitted, the CLI will use the default format specified in the configuration file. Learn more about output formatting. -
--forceForces the command to execute without prompting for confirmation. Use with caution. -
--quietSuppresses all informational output except for errors. Useful for scripting and automation.