Skip to main content

gateways

Creates, updates, deletes, gets or lists a gateways resource.

Overview

Namegateways
TypeResource
Idaws.backup_gateway.gateways

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
deprecation_datestring (date-time)Date after which this gateway will not receive software updates for new features and bug fixes.
gateway_arnstringThe Amazon Resource Name (ARN) of the gateway. Use the ListGateways operation to return a list of gateways for your account and Amazon Web Services Region. (pattern: <code>arn:(aws|aws-cn|aws-us-gov):backup-gateway(:[a-zA-Z-0-9]+){3}/[a-zA-Z-0-9]+</code>)
gateway_display_namestringThe display name of the gateway. (pattern: <code>[a-zA-Z0-9-]*</code>)
gateway_typestringThe type of the gateway type. (BACKUP_VM)
hypervisor_idstringThe hypervisor ID of the gateway.
last_seen_timestring (date-time)Details showing the last time Backup gateway communicated with the cloud, in Unix format and UTC time.
maintenance_start_timeobjectReturns your gateway's weekly maintenance start time including the day and time of the week. Note that values are in terms of the gateway's time zone. Can be weekly or monthly.
next_update_availability_timestring (date-time)Details showing the next update availability time of the gateway.
software_versionstringThe version number of the software running on the gateway appliance. (pattern: <code>[a-zA-Z0-9-]*</code>)
vpc_endpointstringThe DNS name for the virtual private cloud (VPC) endpoint the gateway uses to connect to the cloud for backup gateway.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_gatewayselectregionBy providing the ARN (Amazon Resource Name), this API returns the gateway.
list_gatewaysselectregionLists backup gateways owned by an Amazon Web Services account in an Amazon Web Services Region. The returned list is ordered by gateway Amazon Resource Name (ARN).
create_gatewayinsertregion, ActivationKey, GatewayDisplayName, GatewayTypeCreates a backup gateway. After you create a gateway, you can associate it with a server using the AssociateGatewayToServer operation.
associate_gateway_to_serverupdateregion, GatewayArn, ServerArnAssociates a backup gateway with your server. After you complete the association process, you can back up and restore your VMs through the gateway.
disassociate_gateway_from_serverupdateregion, GatewayArnDisassociates a backup gateway from the specified server. After the disassociation process finishes, the gateway can no longer access the virtual machines on the server.
put_maintenance_start_timereplaceregion, GatewayArn, HourOfDay, MinuteOfHourSet the maintenance start time for a gateway.
delete_gatewaydeleteregionDeletes a backup gateway.
update_gateway_informationexecregion, GatewayArnUpdates a gateway's name. Specify which gateway to update using the Amazon Resource Name (ARN) of the gateway in your request.
update_gateway_software_nowexecregion, GatewayArnUpdates the gateway virtual machine (VM) software. The request immediately triggers the software update. When you make this request, you get a 200 OK success response immediately. However, it might take some time for the update to complete.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

By providing the ARN (Amazon Resource Name), this API returns the gateway.

SELECT
deprecation_date,
gateway_arn,
gateway_display_name,
gateway_type,
hypervisor_id,
last_seen_time,
maintenance_start_time,
next_update_availability_time,
software_version,
vpc_endpoint
FROM aws.backup_gateway.gateways
WHERE region = '{{ region }}' -- required
;

INSERT examples

Creates a backup gateway. After you create a gateway, you can associate it with a server using the AssociateGatewayToServer operation.

INSERT INTO aws.backup_gateway.gateways (
ActivationKey,
GatewayDisplayName,
GatewayType,
Tags,
region
)
SELECT
'{{ ActivationKey }}' /* required */,
'{{ GatewayDisplayName }}' /* required */,
'{{ GatewayType }}' /* required */,
'{{ Tags }}',
'{{ region }}'
RETURNING
gateway_arn
;

UPDATE examples

Associates a backup gateway with your server. After you complete the association process, you can back up and restore your VMs through the gateway.

UPDATE aws.backup_gateway.gateways
SET
GatewayArn = '{{ GatewayArn }}',
ServerArn = '{{ ServerArn }}'
WHERE
region = '{{ region }}' --required
AND GatewayArn = '{{ GatewayArn }}' --required
AND ServerArn = '{{ ServerArn }}' --required
RETURNING
gateway_arn;

REPLACE examples

Set the maintenance start time for a gateway.

REPLACE aws.backup_gateway.gateways
SET
GatewayArn = '{{ GatewayArn }}',
HourOfDay = {{ HourOfDay }},
MinuteOfHour = {{ MinuteOfHour }},
DayOfWeek = {{ DayOfWeek }},
DayOfMonth = {{ DayOfMonth }}
WHERE
region = '{{ region }}' --required
AND GatewayArn = '{{ GatewayArn }}' --required
AND HourOfDay = '{{ HourOfDay }}' --required
AND MinuteOfHour = '{{ MinuteOfHour }}' --required
RETURNING
gateway_arn;

DELETE examples

Deletes a backup gateway.

DELETE FROM aws.backup_gateway.gateways
WHERE region = '{{ region }}' --required
;

Lifecycle Methods

Updates a gateway's name. Specify which gateway to update using the Amazon Resource Name (ARN) of the gateway in your request.

EXEC aws.backup_gateway.gateways.update_gateway_information
@region='{{ region }}' --required
@@json=
'{
"GatewayArn": "{{ GatewayArn }}",
"GatewayDisplayName": "{{ GatewayDisplayName }}"
}'
;