Aliases
Helper methods for image aliases.
List¶
List image aliases
Parameters & Call
Parameter | Type | Description | Default |
---|---|---|---|
remote | string | LXD remote | local |
mutator | function | Mutation function |
$client->lxd->images->aliases->list('local');
Response
[ "/1.0/images/aliases/alias-name" ]
Info¶
Get image alias information.
Parameters & Call
Parameter | Type | Description | Default |
---|---|---|---|
remote | string | LXD remote | local |
name | string | Alias name | |
mutator | function | Mutation function |
$client->lxd->images->aliases->info('local', 'alias-name');
Response
{ "description": "The alias description", "name": "alias-name", "target": "<image fingerprint>" }
Create¶
Get image alias information.
Parameters & Call
Parameter | Type | Description | Default |
---|---|---|---|
remote | string | LXD remote | local |
options | object | Alias options | |
mutator | function | Mutation function |
$client->lxd->images->aliases->create('local', [ "description" => "The alias description", "target" => "<image fingerprint>", "name" => "alias-name" ]);
Response
{ }
Replace¶
Replace alias target or description.
Parameters & Call
Parameter | Type | Description | Default |
---|---|---|---|
remote | string | LXD remote | local |
name | string | Alias name | |
options | object | Alias options | |
mutator | function | Mutation function |
$client->lxd->images->aliases->replace('local', 'alias-name', [ "description" => "New description", "target" => "<image fingerprint>" ]);
Response
{ }
Update¶
Update alias target or description.
Parameters & Call
Parameter | Type | Description | Default |
---|---|---|---|
remote | string | LXD remote | local |
name | string | Alias name | |
options | object | Images options | |
mutator | function | Mutation function |
$client->lxd->images->aliases->update('local', 'alias-name', [ "description" => "New description", "target" => "<image fingerprint>" ]);
Response
{ }
Rename¶
Rename an image alias.
Parameters & Call
Parameter | Type | Description | Default |
---|---|---|---|
remote | string | LXD remote | local |
name | string | Alias name | |
options | object | Images options | |
mutator | function | Mutation function |
$client->lxd->images->aliases->rename('local', 'alias-name', [ "name": "new-name" ]);
Response
{ }
Delete¶
Delete an image alias.
Parameters & Call
Parameter | Type | Description | Default |
---|---|---|---|
remote | string | LXD remote | local |
name | name | Alias name | |
mutator | function | Mutation function |
$client->lxd->images->aliases->delete('local', 'alias-name');
Response
{ }