Sha256: 69a7d3488dba43b8d4f1c05aa1866bc52b0a6b65a948bda6d141be95b0c6deb9
Contents?: true
Size: 974 Bytes
Versions: 3
Compression:
Stored size: 974 Bytes
Contents
require 'fog/core/collection' require 'fog/azurerm/models/resources/deployment' module Fog module Resources class AzureRM # Deployments collection class class Deployments < Fog::Collection attribute :resource_group model Fog::Resources::AzureRM::Deployment def all requires :resource_group deployments = [] service.list_deployments(resource_group).each do |deployment| deployments << Fog::Resources::AzureRM::Deployment.parse(deployment) end load(deployments) end def get(resource_group_name, deployment_name) deployment = service.get_deployment(resource_group_name, deployment_name) deployment_object = Fog::Resources::AzureRM::Deployment.new(service: service) deployment_object.merge_attributes(Fog::Resources::AzureRM::Deployment.parse(deployment)) end end end end end
Version data entries
3 entries across 3 versions & 1 rubygems