VM::EC2::Tag(3pm)
π VM::EC2::Tag π
okay bestie, so this is VM::EC2::Tag β a lil object that describes a tagged Amazon EC2 resource β¨ it's part of the User Contributed Perl Documentation, and it is genuinely so slay for knowing what's tagged with what π·οΈ
β¨ SYNOPSIS β¨
like, the whole vibe is this:
use VM::EC2;
$ec2 = VM::EC2->new(...);
@tags = $ec2->describe_tags(-filter=> {'resource-type'=>'volume'});
for my $t (@tags) {
$id = $t->resourceId;
$type = $t->resourceType;
$key = $t->key;
$value = $t->value;
}
that's it. that's the energy. π
πΈ DESCRIPTION πΈ
so this object is what you use to describe an Amazon EC2 tag π each one carries info about the resource it's tagging, the tag key, and the tag value. tags get handed to you by the VM::EC2->describe_tags() method, no cap.
ngl tho β most of the time you do NOT wanna touch this object directly π instead you'd:
- read tags by calling a resource object's
tags()method, which returns a hash of key value pairs π - or specify particular tag values as one of the filters in a
describe_*()call β¨
that's the main character route, fr fr.
π¦ METHODS π¦
here's the lineup of object methods, all iconic:
resourceIdβ the ID of the resource being tagged πresourceTypeβ the type of the resource being tagged, e.g."image"πkeyβ the tag key πvalueβ the tag value β
π STRING OVERLOADING π
when you use this object in a string context, it will interpolate the resourceId πͺ like it just knows what you meant. obsessed.
π SEE ALSO π
VM::EC2VM::EC2::Generic
go read those too, iykyk π«Ά
π AUTHOR π
Lincoln Stein <lincoln.stein@gmail.com>. π
Copyright (c) 2011 Ontario Institute for Cancer Research
This package and its accompanying libraries is free software; you can redistribute it and/or modify it under the terms of the GPL (either version 1, or at your option, any later version) or the Artistic License 2.0. Refer to LICENSE for the full license text. In addition, please see DISCLAIMER.txt for disclaimers of warranty. π
not me ending on legal text but periodt, the license matters bestie π
perl v5.38.2 Β· 2024-08-10 Β· and that's the whole VM::EC2::Tag(3pm) situation πΈ tysm for reading, mwah πβ¨
π¦ where this page comes from
- debian trixie: libvm-ec2-perl 1.28-5 Β· Artistic-2.0 OR GPL-1.0-or-later
- ubuntu resolute: libvm-ec2-perl 1.28-5 Β· Artistic-2.0 OR GPL-1.0-or-later
- ubuntu stonking: libvm-ec2-perl 1.28-5 Β· Artistic-2.0 OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms