balena-cli
Version:
The official balena Command Line Interface
149 lines (148 loc) • 7.03 kB
TypeScript
import { Command } from '@oclif/core';
import type { Application, BalenaSDK, Release } from 'balena-sdk';
import type { Preloader } from 'balena-preload';
export default class PreloadCmd extends Command {
static description: string;
static examples: string[];
static args: {
image: import("@oclif/core/lib/interfaces").Arg<string, Record<string, unknown>>;
};
static flags: {
dockerPort: import("@oclif/core/lib/interfaces").OptionFlag<number | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
docker: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
dockerHost: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
ca: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
cert: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
key: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
fleet: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
commit: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
'splash-image': import("@oclif/core/lib/interfaces").OptionFlag<string | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
'dont-check-arch': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
'pin-device-to-release': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
'additional-space': import("@oclif/core/lib/interfaces").OptionFlag<number | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
'add-certificate': import("@oclif/core/lib/interfaces").OptionFlag<string[] | undefined, import("@oclif/core/lib/interfaces").CustomOptions>;
};
static authenticated: boolean;
static primary: boolean;
run(): Promise<void>;
readonly applicationExpandOptions: {
owns__release: {
$select: ("id" | "commit" | "composition" | "end_timestamp")[];
$expand: {
contains__image: {
$select: "image"[];
$expand: {
image: {
$select: ("is_stored_at__image_location" | "image_size")[];
};
};
};
};
$filter: {
status: "success";
};
$orderby: ({
end_timestamp: "desc";
id?: undefined;
} | {
id: "desc";
end_timestamp?: undefined;
})[];
};
should_be_running__release: {
$select: "commit";
};
};
isCurrentCommit(commit: string): commit is "current" | "latest";
getApplicationsWithSuccessfulBuilds(deviceTypeSlug: string): Promise<(Omit<import("balena-sdk/typings/pinejs-client-core").SelectResultObject<Application, "slug" | "id" | "should_track_latest_release">, "should_be_running__release" | "owns__release"> & import("balena-sdk/typings/pinejs-client-core").ExpandResourceExpandObject<Application, {
owns__release: {
$select: ("id" | "commit" | "composition" | "end_timestamp")[];
$expand: {
contains__image: {
$select: "image"[];
$expand: {
image: {
$select: ("is_stored_at__image_location" | "image_size")[];
};
};
};
};
$filter: {
status: "success";
};
$orderby: ({
end_timestamp: "desc";
id?: undefined;
} | {
id: "desc";
end_timestamp?: undefined;
})[];
};
should_be_running__release: {
$select: "commit";
};
}>)[]>;
selectApplication(deviceTypeSlug: string): Promise<Omit<import("balena-sdk/typings/pinejs-client-core").SelectResultObject<Application, "slug" | "id" | "should_track_latest_release">, "should_be_running__release" | "owns__release"> & import("balena-sdk/typings/pinejs-client-core").ExpandResourceExpandObject<Application, {
owns__release: {
$select: ("id" | "commit" | "composition" | "end_timestamp")[];
$expand: {
contains__image: {
$select: "image"[];
$expand: {
image: {
$select: ("is_stored_at__image_location" | "image_size")[];
};
};
};
};
$filter: {
status: "success";
};
$orderby: ({
end_timestamp: "desc";
id?: undefined;
} | {
id: "desc";
end_timestamp?: undefined;
})[];
};
should_be_running__release: {
$select: "commit";
};
}>>;
selectApplicationCommit(releases: Release[]): Promise<string>;
offerToDisableAutomaticUpdates(application: Pick<Application, 'id' | 'should_track_latest_release'>, commit: string, pinDevice: boolean | undefined): Promise<"OK" | undefined>;
getAppWithReleases(balenaSdk: BalenaSDK, slug: string): Promise<Omit<import("balena-sdk/typings/pinejs-client-core").SelectResultObject<Application, import("balena-sdk/typings/utils").StringKeyof<Application>>, "should_be_running__release" | "owns__release"> & import("balena-sdk/typings/pinejs-client-core").ExpandResourceExpandObject<Application, {
owns__release: {
$select: ("id" | "commit" | "composition" | "end_timestamp")[];
$expand: {
contains__image: {
$select: "image"[];
$expand: {
image: {
$select: ("is_stored_at__image_location" | "image_size")[];
};
};
};
};
$filter: {
status: "success";
};
$orderby: ({
end_timestamp: "desc";
id?: undefined;
} | {
id: "desc";
end_timestamp?: undefined;
})[];
};
should_be_running__release: {
$select: "commit";
};
}>>;
prepareAndPreload(preloader: Preloader, balenaSdk: BalenaSDK, options: {
slug?: string;
commit?: string;
pinDevice?: boolean;
}): Promise<void>;
}