fog-aws 3.5.0 → 3.28.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +12 -765
- data/LICENSE.md +1 -1
- data/README.md +117 -7
- data/fog-aws.gemspec +14 -11
- data/lib/fog/aws/auto_scaling.rb +1 -1
- data/lib/fog/aws/beanstalk.rb +1 -1
- data/lib/fog/aws/cdn.rb +1 -1
- data/lib/fog/aws/cloud_formation.rb +1 -1
- data/lib/fog/aws/cloud_watch.rb +1 -1
- data/lib/fog/aws/compute.rb +8 -5
- data/lib/fog/aws/credential_fetcher.rb +89 -7
- data/lib/fog/aws/data_pipeline.rb +1 -1
- data/lib/fog/aws/dns.rb +137 -1
- data/lib/fog/aws/dynamodb.rb +1 -1
- data/lib/fog/aws/ecs.rb +1 -1
- data/lib/fog/aws/elasticache.rb +6 -4
- data/lib/fog/aws/elb.rb +2 -2
- data/lib/fog/aws/elbv2.rb +72 -0
- data/lib/fog/aws/emr.rb +1 -1
- data/lib/fog/aws/glacier.rb +84 -22
- data/lib/fog/aws/iam.rb +1 -1
- data/lib/fog/aws/kinesis.rb +24 -16
- data/lib/fog/aws/kms.rb +1 -1
- data/lib/fog/aws/lambda.rb +1 -1
- data/lib/fog/aws/models/compute/dhcp_option.rb +1 -1
- data/lib/fog/aws/models/compute/flavors.rb +3803 -531
- data/lib/fog/aws/models/compute/network_interfaces.rb +1 -1
- data/lib/fog/aws/models/compute/security_group.rb +13 -5
- data/lib/fog/aws/models/compute/server.rb +6 -2
- data/lib/fog/aws/models/compute/servers.rb +2 -0
- data/lib/fog/aws/models/compute/snapshot.rb +7 -6
- data/lib/fog/aws/models/compute/vpc.rb +8 -2
- data/lib/fog/aws/models/elasticache/cluster.rb +1 -1
- data/lib/fog/aws/models/storage/directories.rb +1 -0
- data/lib/fog/aws/models/storage/directory.rb +0 -1
- data/lib/fog/aws/models/storage/file.rb +168 -23
- data/lib/fog/aws/models/storage/files.rb +33 -2
- data/lib/fog/aws/parsers/compute/create_snapshot.rb +1 -1
- data/lib/fog/aws/parsers/compute/create_subnet.rb +33 -6
- data/lib/fog/aws/parsers/compute/describe_security_groups.rb +18 -4
- data/lib/fog/aws/parsers/compute/describe_subnets.rb +33 -6
- data/lib/fog/aws/parsers/dns/create_hosted_zone.rb +1 -1
- data/lib/fog/aws/parsers/dns/get_hosted_zone.rb +3 -3
- data/lib/fog/aws/parsers/dns/list_hosted_zones.rb +3 -1
- data/lib/fog/aws/parsers/elbv2/create_load_balancer.rb +88 -0
- data/lib/fog/aws/parsers/elbv2/describe_listeners.rb +110 -0
- data/lib/fog/aws/parsers/elbv2/describe_load_balancers.rb +88 -0
- data/lib/fog/aws/parsers/elbv2/describe_tags.rb +53 -0
- data/lib/fog/aws/parsers/elbv2/empty.rb +10 -0
- data/lib/fog/aws/parsers/iam/get_group_policy.rb +1 -1
- data/lib/fog/aws/parsers/iam/get_role_policy.rb +1 -1
- data/lib/fog/aws/parsers/iam/get_user_policy.rb +1 -1
- data/lib/fog/aws/parsers/iam/list_server_certificates.rb +1 -1
- data/lib/fog/aws/parsers/iam/policy_version.rb +1 -1
- data/lib/fog/aws/parsers/rds/db_cluster_parser.rb +1 -1
- data/lib/fog/aws/parsers/rds/db_parser.rb +1 -1
- data/lib/fog/aws/parsers/rds/modify_db_subnet_group.rb +1 -1
- data/lib/fog/aws/parsers/redshift/cluster_subnet_group_parser.rb +1 -1
- data/lib/fog/aws/parsers/storage/get_object_tagging.rb +33 -0
- data/lib/fog/aws/parsers/storage/upload_part_copy_object.rb +18 -0
- data/lib/fog/aws/parsers/sts/assume_role_with_web_identity.rb +1 -1
- data/lib/fog/aws/rds.rb +1 -1
- data/lib/fog/aws/redshift.rb +1 -1
- data/lib/fog/aws/requests/auto_scaling/attach_load_balancer_target_groups.rb +1 -1
- data/lib/fog/aws/requests/auto_scaling/describe_scaling_activities.rb +1 -1
- data/lib/fog/aws/requests/auto_scaling/put_scheduled_update_group_action.rb +1 -1
- data/lib/fog/aws/requests/cloud_formation/create_change_set.rb +1 -1
- data/lib/fog/aws/requests/cloud_formation/create_stack.rb +1 -1
- data/lib/fog/aws/requests/cloud_formation/get_template_summary.rb +1 -1
- data/lib/fog/aws/requests/cloud_formation/update_stack.rb +1 -1
- data/lib/fog/aws/requests/cloud_watch/list_metrics.rb +1 -1
- data/lib/fog/aws/requests/compute/authorize_security_group_egress.rb +1 -1
- data/lib/fog/aws/requests/compute/authorize_security_group_ingress.rb +16 -1
- data/lib/fog/aws/requests/compute/create_network_interface.rb +8 -5
- data/lib/fog/aws/requests/compute/create_subnet.rb +3 -3
- data/lib/fog/aws/requests/compute/create_vpc.rb +3 -3
- data/lib/fog/aws/requests/compute/describe_network_interfaces.rb +2 -2
- data/lib/fog/aws/requests/compute/describe_security_groups.rb +2 -0
- data/lib/fog/aws/requests/compute/modify_network_interface_attribute.rb +1 -1
- data/lib/fog/aws/requests/compute/modify_volume.rb +1 -1
- data/lib/fog/aws/requests/compute/request_spot_instances.rb +1 -1
- data/lib/fog/aws/requests/compute/revoke_security_group_egress.rb +1 -1
- data/lib/fog/aws/requests/compute/revoke_security_group_ingress.rb +1 -1
- data/lib/fog/aws/requests/compute/run_instances.rb +64 -0
- data/lib/fog/aws/requests/compute/stop_instances.rb +11 -3
- data/lib/fog/aws/requests/data_pipeline/deactivate_pipeline.rb +1 -1
- data/lib/fog/aws/requests/dns/change_resource_record_sets.rb +0 -133
- data/lib/fog/aws/requests/ecs/list_task_definitions.rb +1 -1
- data/lib/fog/aws/requests/efs/create_file_system.rb +1 -1
- data/lib/fog/aws/requests/elasticache/authorize_cache_security_group_ingress.rb +1 -1
- data/lib/fog/aws/requests/elasticache/create_cache_cluster.rb +2 -2
- data/lib/fog/aws/requests/elasticache/describe_engine_default_parameters.rb +1 -1
- data/lib/fog/aws/requests/elb/delete_load_balancer_listeners.rb +1 -1
- data/lib/fog/aws/requests/elbv2/add_tags.rb +45 -0
- data/lib/fog/aws/requests/elbv2/create_load_balancer.rb +160 -0
- data/lib/fog/aws/requests/elbv2/describe_listeners.rb +38 -0
- data/lib/fog/aws/requests/elbv2/describe_load_balancers.rb +100 -0
- data/lib/fog/aws/requests/elbv2/describe_tags.rb +50 -0
- data/lib/fog/aws/requests/elbv2/remove_tags.rb +45 -0
- data/lib/fog/aws/requests/glacier/initiate_job.rb +1 -1
- data/lib/fog/aws/requests/glacier/initiate_multipart_upload.rb +1 -1
- data/lib/fog/aws/requests/kinesis/list_streams.rb +1 -1
- data/lib/fog/aws/requests/lambda/invoke.rb +7 -7
- data/lib/fog/aws/requests/rds/add_tags_to_resource.rb +12 -10
- data/lib/fog/aws/requests/rds/authorize_db_security_group_ingress.rb +2 -2
- data/lib/fog/aws/requests/rds/create_db_cluster.rb +1 -1
- data/lib/fog/aws/requests/rds/describe_db_snapshots.rb +1 -1
- data/lib/fog/aws/requests/rds/list_tags_for_resource.rb +10 -7
- data/lib/fog/aws/requests/rds/modify_db_instance.rb +1 -1
- data/lib/fog/aws/requests/rds/modify_db_parameter_group.rb +1 -1
- data/lib/fog/aws/requests/rds/remove_tags_from_resource.rb +9 -8
- data/lib/fog/aws/requests/ses/send_raw_email.rb +1 -1
- data/lib/fog/aws/requests/sqs/change_message_visibility.rb +1 -1
- data/lib/fog/aws/requests/sqs/delete_message.rb +1 -1
- data/lib/fog/aws/requests/storage/copy_object.rb +2 -1
- data/lib/fog/aws/requests/storage/delete_multiple_objects.rb +18 -8
- data/lib/fog/aws/requests/storage/get_bucket.rb +2 -2
- data/lib/fog/aws/requests/storage/get_bucket_object_versions.rb +2 -2
- data/lib/fog/aws/requests/storage/get_object.rb +1 -1
- data/lib/fog/aws/requests/storage/get_object_tagging.rb +41 -0
- data/lib/fog/aws/requests/storage/get_service.rb +1 -1
- data/lib/fog/aws/requests/storage/list_parts.rb +1 -1
- data/lib/fog/aws/requests/storage/put_bucket.rb +0 -4
- data/lib/fog/aws/requests/storage/put_bucket_lifecycle.rb +1 -1
- data/lib/fog/aws/requests/storage/put_bucket_notification.rb +1 -1
- data/lib/fog/aws/requests/storage/put_object.rb +1 -1
- data/lib/fog/aws/requests/storage/put_object_tagging.rb +42 -0
- data/lib/fog/aws/requests/storage/shared_mock_methods.rb +2 -1
- data/lib/fog/aws/requests/storage/sync_clock.rb +9 -1
- data/lib/fog/aws/requests/storage/upload_part_copy.rb +119 -0
- data/lib/fog/aws/requests/sts/assume_role_with_web_identity.rb +7 -6
- data/lib/fog/aws/ses.rb +20 -17
- data/lib/fog/aws/signaturev4.rb +1 -1
- data/lib/fog/aws/simpledb.rb +1 -1
- data/lib/fog/aws/sns.rb +1 -1
- data/lib/fog/aws/sqs.rb +1 -1
- data/lib/fog/aws/storage.rb +78 -13
- data/lib/fog/aws/support.rb +1 -1
- data/lib/fog/aws/version.rb +1 -1
- data/lib/fog/aws.rb +11 -2
- metadata +49 -294
- data/.gitignore +0 -16
- data/.travis.yml +0 -53
- data/Gemfile +0 -14
- data/Rakefile +0 -14
- data/gemfiles/Gemfile-edge +0 -14
- data/gemfiles/Gemfile-ruby-2.0 +0 -7
- data/stale.yml +0 -17
- data/tests/credentials_tests.rb +0 -87
- data/tests/helper.rb +0 -29
- data/tests/helpers/collection_helper.rb +0 -90
- data/tests/helpers/compute/flavors_helper.rb +0 -28
- data/tests/helpers/compute/server_helper.rb +0 -23
- data/tests/helpers/compute/servers_helper.rb +0 -8
- data/tests/helpers/dns_helper.rb +0 -56
- data/tests/helpers/formats_helper.rb +0 -100
- data/tests/helpers/formats_helper_tests.rb +0 -107
- data/tests/helpers/mock_helper.rb +0 -109
- data/tests/helpers/model_helper.rb +0 -30
- data/tests/helpers/responds_to_helper.rb +0 -11
- data/tests/helpers/schema_validator_tests.rb +0 -104
- data/tests/helpers/succeeds_helper.rb +0 -9
- data/tests/lorem.txt +0 -1
- data/tests/models/auto_scaling/activities_tests.rb +0 -6
- data/tests/models/auto_scaling/configuration_test.rb +0 -13
- data/tests/models/auto_scaling/configurations_tests.rb +0 -11
- data/tests/models/auto_scaling/groups_test.rb +0 -27
- data/tests/models/auto_scaling/helper.rb +0 -0
- data/tests/models/auto_scaling/instance_tests.rb +0 -15
- data/tests/models/auto_scaling/instances_tests.rb +0 -6
- data/tests/models/beanstalk/application_tests.rb +0 -69
- data/tests/models/beanstalk/applications_tests.rb +0 -7
- data/tests/models/beanstalk/environment_tests.rb +0 -131
- data/tests/models/beanstalk/environments_tests.rb +0 -34
- data/tests/models/beanstalk/template_tests.rb +0 -47
- data/tests/models/beanstalk/templates_tests.rb +0 -62
- data/tests/models/beanstalk/version_tests.rb +0 -66
- data/tests/models/beanstalk/versions_tests.rb +0 -60
- data/tests/models/cdn/distribution_tests.rb +0 -15
- data/tests/models/cdn/distributions_tests.rb +0 -15
- data/tests/models/cdn/invalidation_tests.rb +0 -31
- data/tests/models/cdn/invalidations_tests.rb +0 -14
- data/tests/models/cdn/streaming_distribution_tests.rb +0 -15
- data/tests/models/cdn/streaming_distributions_tests.rb +0 -15
- data/tests/models/cloud_watch/alarm_data_tests.rb +0 -42
- data/tests/models/cloud_watch/alarm_history_tests.rb +0 -22
- data/tests/models/cloud_watch/metric_statistics_tests.rb +0 -51
- data/tests/models/cloud_watch/metrics_tests.rb +0 -32
- data/tests/models/compute/address_tests.rb +0 -43
- data/tests/models/compute/addresses_tests.rb +0 -5
- data/tests/models/compute/dhcp_option_tests.rb +0 -3
- data/tests/models/compute/dhcp_options_tests.rb +0 -3
- data/tests/models/compute/internet_gateway_tests.rb +0 -3
- data/tests/models/compute/internet_gateways_tests.rb +0 -3
- data/tests/models/compute/key_pair_tests.rb +0 -26
- data/tests/models/compute/key_pairs_tests.rb +0 -5
- data/tests/models/compute/network_acl_tests.rb +0 -109
- data/tests/models/compute/network_acls_tests.rb +0 -20
- data/tests/models/compute/network_interfaces_test.rb +0 -12
- data/tests/models/compute/security_group_tests.rb +0 -98
- data/tests/models/compute/security_groups_tests.rb +0 -5
- data/tests/models/compute/server_tests.rb +0 -94
- data/tests/models/compute/snapshot_tests.rb +0 -10
- data/tests/models/compute/snapshots_tests.rb +0 -10
- data/tests/models/compute/subnet_tests.rb +0 -13
- data/tests/models/compute/subnets_tests.rb +0 -5
- data/tests/models/compute/volume_tests.rb +0 -65
- data/tests/models/compute/volumes_tests.rb +0 -5
- data/tests/models/compute/vpc_tests.rb +0 -26
- data/tests/models/compute/vpcs_tests.rb +0 -19
- data/tests/models/data_pipeline/pipeline_tests.rb +0 -8
- data/tests/models/data_pipeline/pipelines_tests.rb +0 -8
- data/tests/models/dns/record_tests.rb +0 -33
- data/tests/models/dns/records_tests.rb +0 -41
- data/tests/models/dns/zone_tests.rb +0 -4
- data/tests/models/dns/zones_tests.rb +0 -4
- data/tests/models/efs/file_system_tests.rb +0 -12
- data/tests/models/efs/mount_target_tests.rb +0 -45
- data/tests/models/efs/mount_targets_tests.rb +0 -30
- data/tests/models/elasticache/cluster_tests.rb +0 -30
- data/tests/models/elasticache/parameter_groups_tests.rb +0 -15
- data/tests/models/elasticache/security_groups_tests.rb +0 -52
- data/tests/models/elasticache/subnet_groups_tests.rb +0 -43
- data/tests/models/elb/model_tests.rb +0 -360
- data/tests/models/elb/tagging_tests.rb +0 -15
- data/tests/models/glacier/model_tests.rb +0 -47
- data/tests/models/iam/access_keys_tests.rb +0 -53
- data/tests/models/iam/groups_tests.rb +0 -59
- data/tests/models/iam/instance_profile_tests.rb +0 -18
- data/tests/models/iam/managed_policies_tests.rb +0 -89
- data/tests/models/iam/policies_tests.rb +0 -57
- data/tests/models/iam/roles_tests.rb +0 -71
- data/tests/models/iam/users_tests.rb +0 -119
- data/tests/models/rds/cluster_tests.rb +0 -54
- data/tests/models/rds/clusters_tests.rb +0 -5
- data/tests/models/rds/event_subscription_tests.rb +0 -9
- data/tests/models/rds/event_subscriptions_tests.rb +0 -6
- data/tests/models/rds/helper.rb +0 -25
- data/tests/models/rds/instance_option_tests.rb +0 -14
- data/tests/models/rds/parameter_group_tests.rb +0 -24
- data/tests/models/rds/parameter_groups_tests.rb +0 -8
- data/tests/models/rds/security_group_tests.rb +0 -77
- data/tests/models/rds/security_groups_tests.rb +0 -5
- data/tests/models/rds/server_tests.rb +0 -131
- data/tests/models/rds/servers_tests.rb +0 -24
- data/tests/models/rds/snapshot_tests.rb +0 -12
- data/tests/models/rds/snapshots_tests.rb +0 -12
- data/tests/models/rds/tagging_tests.rb +0 -20
- data/tests/models/sns/topic_tests.rb +0 -15
- data/tests/models/sns/topics_tests.rb +0 -6
- data/tests/models/storage/directory_tests.rb +0 -91
- data/tests/models/storage/file_tests.rb +0 -129
- data/tests/models/storage/files_tests.rb +0 -58
- data/tests/models/storage/url_tests.rb +0 -25
- data/tests/models/storage/version_tests.rb +0 -52
- data/tests/models/storage/versions_tests.rb +0 -51
- data/tests/models/support/trusted_advisor_tests.rb +0 -25
- data/tests/parsers/compute/describe_images_tests.rb +0 -33
- data/tests/parsers/elb/describe_load_balancers.rb +0 -65
- data/tests/requests/auto_scaling/auto_scaling_tests.rb +0 -111
- data/tests/requests/auto_scaling/describe_types_tests.rb +0 -102
- data/tests/requests/auto_scaling/helper.rb +0 -229
- data/tests/requests/auto_scaling/model_tests.rb +0 -235
- data/tests/requests/auto_scaling/notification_configuration_tests.rb +0 -124
- data/tests/requests/auto_scaling/tag_tests.rb +0 -63
- data/tests/requests/beanstalk/application_tests.rb +0 -140
- data/tests/requests/beanstalk/solution_stack_tests.rb +0 -22
- data/tests/requests/cdn/cdn_tests.rb +0 -252
- data/tests/requests/cloud_formation/stack_tests.rb +0 -167
- data/tests/requests/cloud_watch/get_metric_statistics_tests.rb +0 -28
- data/tests/requests/cloud_watch/list_metrics_test.rb +0 -64
- data/tests/requests/cloud_watch/put_metric_data_tests.rb +0 -36
- data/tests/requests/compute/address_tests.rb +0 -144
- data/tests/requests/compute/assign_private_ip_tests.rb +0 -55
- data/tests/requests/compute/availability_zone_tests.rb +0 -25
- data/tests/requests/compute/client_tests.rb +0 -25
- data/tests/requests/compute/dhcp_options_tests.rb +0 -39
- data/tests/requests/compute/helper.rb +0 -27
- data/tests/requests/compute/image_tests.rb +0 -169
- data/tests/requests/compute/instance_attrib_tests.rb +0 -168
- data/tests/requests/compute/instance_tests.rb +0 -338
- data/tests/requests/compute/internet_gateway_tests.rb +0 -49
- data/tests/requests/compute/key_pair_tests.rb +0 -67
- data/tests/requests/compute/network_acl_tests.rb +0 -112
- data/tests/requests/compute/network_interface_tests.rb +0 -239
- data/tests/requests/compute/placement_group_tests.rb +0 -48
- data/tests/requests/compute/region_tests.rb +0 -52
- data/tests/requests/compute/route_tests.rb +0 -341
- data/tests/requests/compute/security_group_tests.rb +0 -446
- data/tests/requests/compute/snapshot_tests.rb +0 -77
- data/tests/requests/compute/spot_datafeed_subscription_tests.rb +0 -47
- data/tests/requests/compute/spot_instance_tests.rb +0 -55
- data/tests/requests/compute/spot_price_history_tests.rb +0 -23
- data/tests/requests/compute/subnet_tests.rb +0 -87
- data/tests/requests/compute/tag_tests.rb +0 -101
- data/tests/requests/compute/volume_tests.rb +0 -263
- data/tests/requests/compute/vpc_tests.rb +0 -216
- data/tests/requests/data_pipeline/helper.rb +0 -78
- data/tests/requests/data_pipeline/pipeline_tests.rb +0 -80
- data/tests/requests/dns/change_resource_record_sets_tests.rb +0 -34
- data/tests/requests/dns/dns_tests.rb +0 -240
- data/tests/requests/dns/health_check_tests.rb +0 -159
- data/tests/requests/dns/helper.rb +0 -21
- data/tests/requests/dynamodb/item_tests.rb +0 -137
- data/tests/requests/dynamodb/table_tests.rb +0 -99
- data/tests/requests/ecs/cluster_tests.rb +0 -112
- data/tests/requests/ecs/container_instance_tests.rb +0 -119
- data/tests/requests/ecs/helper.rb +0 -276
- data/tests/requests/ecs/sample_task_definition1.json +0 -56
- data/tests/requests/ecs/service_tests.rb +0 -132
- data/tests/requests/ecs/task_definitions_tests.rb +0 -97
- data/tests/requests/ecs/task_tests.rb +0 -145
- data/tests/requests/efs/file_system_tests.rb +0 -152
- data/tests/requests/efs/helper.rb +0 -44
- data/tests/requests/elasticache/cache_cluster_tests.rb +0 -137
- data/tests/requests/elasticache/describe_events.rb +0 -17
- data/tests/requests/elasticache/describe_reserved_cache_nodes.rb +0 -17
- data/tests/requests/elasticache/helper.rb +0 -103
- data/tests/requests/elasticache/parameter_group_tests.rb +0 -105
- data/tests/requests/elasticache/security_group_tests.rb +0 -108
- data/tests/requests/elasticache/subnet_group_tests.rb +0 -52
- data/tests/requests/elb/helper.rb +0 -91
- data/tests/requests/elb/listener_tests.rb +0 -68
- data/tests/requests/elb/load_balancer_tests.rb +0 -89
- data/tests/requests/elb/policy_tests.rb +0 -132
- data/tests/requests/emr/helper.rb +0 -167
- data/tests/requests/emr/instance_group_tests.rb +0 -106
- data/tests/requests/emr/job_flow_tests.rb +0 -88
- data/tests/requests/federation/get_signin_token_tests.rb +0 -11
- data/tests/requests/glacier/archive_tests.rb +0 -13
- data/tests/requests/glacier/multipart_upload_tests.rb +0 -29
- data/tests/requests/glacier/tree_hash_tests.rb +0 -62
- data/tests/requests/glacier/vault_tests.rb +0 -35
- data/tests/requests/iam/access_key_tests.rb +0 -53
- data/tests/requests/iam/account_policy_tests.rb +0 -20
- data/tests/requests/iam/account_tests.rb +0 -34
- data/tests/requests/iam/group_policy_tests.rb +0 -48
- data/tests/requests/iam/group_tests.rb +0 -44
- data/tests/requests/iam/helper.rb +0 -154
- data/tests/requests/iam/instance_profile_tests.rb +0 -44
- data/tests/requests/iam/login_profile_tests.rb +0 -62
- data/tests/requests/iam/managed_policy_tests.rb +0 -110
- data/tests/requests/iam/mfa_tests.rb +0 -23
- data/tests/requests/iam/role_tests.rb +0 -156
- data/tests/requests/iam/server_certificate_tests.rb +0 -130
- data/tests/requests/iam/user_policy_tests.rb +0 -45
- data/tests/requests/iam/user_tests.rb +0 -78
- data/tests/requests/iam/versioned_managed_policy_tests.rb +0 -105
- data/tests/requests/kinesis/helper.rb +0 -111
- data/tests/requests/kinesis/stream_tests.rb +0 -169
- data/tests/requests/kms/helper.rb +0 -27
- data/tests/requests/kms/key_tests.rb +0 -23
- data/tests/requests/lambda/function_sample_1.js +0 -9
- data/tests/requests/lambda/function_sample_2.js +0 -9
- data/tests/requests/lambda/function_tests.rb +0 -460
- data/tests/requests/lambda/helper.rb +0 -81
- data/tests/requests/rds/cluster_snapshot_tests.rb +0 -43
- data/tests/requests/rds/cluster_tests.rb +0 -37
- data/tests/requests/rds/db_engine_versions.rb +0 -7
- data/tests/requests/rds/db_snapshot_tests.rb +0 -62
- data/tests/requests/rds/describe_events.rb +0 -16
- data/tests/requests/rds/event_subscription_tests.rb +0 -30
- data/tests/requests/rds/helper.rb +0 -406
- data/tests/requests/rds/instance_option_tests.rb +0 -27
- data/tests/requests/rds/instance_tests.rb +0 -149
- data/tests/requests/rds/log_file_tests.rb +0 -19
- data/tests/requests/rds/parameter_group_tests.rb +0 -62
- data/tests/requests/rds/parameter_request_tests.rb +0 -32
- data/tests/requests/rds/security_group_tests.rb +0 -101
- data/tests/requests/rds/subnet_groups_tests.rb +0 -52
- data/tests/requests/rds/tagging_tests.rb +0 -78
- data/tests/requests/redshift/cluster_parameter_group_tests.rb +0 -76
- data/tests/requests/redshift/cluster_security_group_tests.rb +0 -42
- data/tests/requests/redshift/cluster_snapshot_tests.rb +0 -73
- data/tests/requests/redshift/cluster_tests.rb +0 -80
- data/tests/requests/ses/helper.rb +0 -9
- data/tests/requests/ses/verified_domain_identity_tests.rb +0 -16
- data/tests/requests/ses/verified_email_address_tests.rb +0 -27
- data/tests/requests/simpledb/attributes_tests.rb +0 -86
- data/tests/requests/simpledb/domain_tests.rb +0 -51
- data/tests/requests/simpledb/helper.rb +0 -10
- data/tests/requests/sns/helper.rb +0 -9
- data/tests/requests/sns/subscription_tests.rb +0 -86
- data/tests/requests/sns/topic_tests.rb +0 -53
- data/tests/requests/sqs/helper.rb +0 -9
- data/tests/requests/sqs/message_tests.rb +0 -51
- data/tests/requests/sqs/queue_tests.rb +0 -50
- data/tests/requests/storage/acl_utils_tests.rb +0 -209
- data/tests/requests/storage/bucket_tests.rb +0 -416
- data/tests/requests/storage/cors_utils_tests.rb +0 -108
- data/tests/requests/storage/delete_multiple_objects_tests.rb +0 -12
- data/tests/requests/storage/multipart_upload_tests.rb +0 -121
- data/tests/requests/storage/object_tests.rb +0 -262
- data/tests/requests/storage/versioning_tests.rb +0 -262
- data/tests/requests/sts/assume_role_tests.rb +0 -19
- data/tests/requests/sts/assume_role_with_saml_tests.rb +0 -18
- data/tests/requests/sts/assume_role_with_web_identity_tests.rb +0 -28
- data/tests/requests/sts/get_federation_token_tests.rb +0 -20
- data/tests/requests/sts/session_token_tests.rb +0 -16
- data/tests/requests/support/helper.rb +0 -43
- data/tests/requests/support/trusted_advisor_check_tests.rb +0 -16
- data/tests/signaturev4_tests.rb +0 -106
- data/tests/signed_params_tests.rb +0 -17
- data/tests/storage_tests.rb +0 -7
data/lib/fog/aws/elasticache.rb
CHANGED
@@ -8,7 +8,7 @@ module Fog
|
|
8
8
|
class AuthorizationAlreadyExists < Fog::Errors::Error; end
|
9
9
|
|
10
10
|
requires :aws_access_key_id, :aws_secret_access_key
|
11
|
-
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :instrumentor, :instrumentor_name
|
11
|
+
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :instrumentor, :instrumentor_name, :sts_endpoint
|
12
12
|
|
13
13
|
request_path 'fog/aws/requests/elasticache'
|
14
14
|
|
@@ -171,8 +171,10 @@ module Fog
|
|
171
171
|
@aws_credentials_expire_at = Time::now + 20
|
172
172
|
setup_credentials(options)
|
173
173
|
@region = options[:region] || 'us-east-1'
|
174
|
-
unless ['ap-
|
175
|
-
'
|
174
|
+
unless ['ap-south-1', 'ap-northeast-1', 'ap-northeast-2', 'ap-northeast-3', 'ap-southeast-1', 'ap-southeast-2',
|
175
|
+
'eu-west-1', 'eu-west-2', 'eu-west-3', 'eu-central-1',
|
176
|
+
'us-east-1', 'us-east-2', 'us-west-1', 'us-west-2', 'ca-central-1',
|
177
|
+
'sa-east-1', 'cn-north-1', 'cn-northwest-1', 'ap-east-1', 'us-gov-west-1'].include?(@region)
|
176
178
|
raise ArgumentError, "Unknown region: #{@region.inspect}"
|
177
179
|
end
|
178
180
|
end
|
@@ -193,7 +195,7 @@ module Fog
|
|
193
195
|
@aws_access_key_id = options[:aws_access_key_id]
|
194
196
|
end
|
195
197
|
|
196
|
-
# returns an Array of (Mock) elasticache nodes,
|
198
|
+
# returns an Array of (Mock) elasticache nodes, represented as Hashes
|
197
199
|
def create_cache_nodes(cluster_id, num_nodes = 1, port = '11211')
|
198
200
|
(1..num_nodes).map do |node_number|
|
199
201
|
node_id = "%04d" % node_number
|
data/lib/fog/aws/elb.rb
CHANGED
@@ -14,7 +14,7 @@ module Fog
|
|
14
14
|
class ValidationError < Fog::Errors::Error; end
|
15
15
|
|
16
16
|
requires :aws_access_key_id, :aws_secret_access_key
|
17
|
-
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :version, :instrumentor, :instrumentor_name
|
17
|
+
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :version, :instrumentor, :instrumentor_name,:sts_endpoint
|
18
18
|
|
19
19
|
request_path 'fog/aws/requests/elb'
|
20
20
|
request :configure_health_check
|
@@ -142,7 +142,7 @@ module Fog
|
|
142
142
|
@port = options[:port] || 443
|
143
143
|
@scheme = options[:scheme] || 'https'
|
144
144
|
@connection = Fog::XML::Connection.new("#{@scheme}://#{@host}:#{@port}#{@path}", @persistent, @connection_options)
|
145
|
-
@version
|
145
|
+
@version ||= options[:version] || '2012-06-01'
|
146
146
|
|
147
147
|
setup_credentials(options)
|
148
148
|
end
|
@@ -0,0 +1,72 @@
|
|
1
|
+
module Fog
|
2
|
+
module AWS
|
3
|
+
class ELBV2 < ELB
|
4
|
+
requires :aws_access_key_id, :aws_secret_access_key
|
5
|
+
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :version, :instrumentor, :instrumentor_name,:sts_endpoint
|
6
|
+
|
7
|
+
request_path 'fog/aws/requests/elbv2'
|
8
|
+
request :add_tags
|
9
|
+
request :create_load_balancer
|
10
|
+
request :describe_tags
|
11
|
+
request :remove_tags
|
12
|
+
request :describe_load_balancers
|
13
|
+
request :describe_listeners
|
14
|
+
|
15
|
+
class Real < ELB::Real
|
16
|
+
def initialize(options={})
|
17
|
+
@version = '2015-12-01'
|
18
|
+
|
19
|
+
super(options)
|
20
|
+
end
|
21
|
+
end
|
22
|
+
|
23
|
+
class Mock
|
24
|
+
def self.data
|
25
|
+
@data ||= Hash.new do |hash, region|
|
26
|
+
owner_id = Fog::AWS::Mock.owner_id
|
27
|
+
hash[region] = Hash.new do |region_hash, key|
|
28
|
+
region_hash[key] = {
|
29
|
+
:owner_id => owner_id,
|
30
|
+
:load_balancers_v2 => {}
|
31
|
+
}
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
35
|
+
|
36
|
+
def self.dns_name(name, region)
|
37
|
+
"#{name}-#{Fog::Mock.random_hex(8)}.#{region}.elb.amazonaws.com"
|
38
|
+
end
|
39
|
+
|
40
|
+
def self.reset
|
41
|
+
@data = nil
|
42
|
+
end
|
43
|
+
|
44
|
+
attr_reader :region
|
45
|
+
|
46
|
+
def initialize(options={})
|
47
|
+
@use_iam_profile = options[:use_iam_profile]
|
48
|
+
|
49
|
+
@region = options[:region] || 'us-east-1'
|
50
|
+
setup_credentials(options)
|
51
|
+
|
52
|
+
Fog::AWS.validate_region!(@region)
|
53
|
+
end
|
54
|
+
|
55
|
+
def setup_credentials(options)
|
56
|
+
@aws_access_key_id = options[:aws_access_key_id]
|
57
|
+
@aws_secret_access_key = options[:aws_secret_access_key]
|
58
|
+
|
59
|
+
@signer = Fog::AWS::SignatureV4.new(@aws_access_key_id, @aws_secret_access_key,@region,'elasticloadbalancing')
|
60
|
+
end
|
61
|
+
|
62
|
+
def data
|
63
|
+
self.class.data[@region][@aws_access_key_id]
|
64
|
+
end
|
65
|
+
|
66
|
+
def reset_data
|
67
|
+
self.class.data[@region].delete(@aws_access_key_id)
|
68
|
+
end
|
69
|
+
end
|
70
|
+
end
|
71
|
+
end
|
72
|
+
end
|
data/lib/fog/aws/emr.rb
CHANGED
@@ -6,7 +6,7 @@ module Fog
|
|
6
6
|
class IdentifierTaken < Fog::Errors::Error; end
|
7
7
|
|
8
8
|
requires :aws_access_key_id, :aws_secret_access_key
|
9
|
-
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :instrumentor, :instrumentor_name
|
9
|
+
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :instrumentor, :instrumentor_name, :sts_endpoint
|
10
10
|
|
11
11
|
request_path 'fog/aws/requests/emr'
|
12
12
|
|
data/lib/fog/aws/glacier.rb
CHANGED
@@ -4,7 +4,7 @@ module Fog
|
|
4
4
|
extend Fog::AWS::CredentialFetcher::ServiceMethods
|
5
5
|
|
6
6
|
requires :aws_access_key_id, :aws_secret_access_key
|
7
|
-
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :instrumentor, :instrumentor_name
|
7
|
+
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :instrumentor, :instrumentor_name, :sts_endpoint
|
8
8
|
|
9
9
|
request_path 'fog/aws/requests/glacier'
|
10
10
|
|
@@ -39,52 +39,114 @@ module Fog
|
|
39
39
|
new.add_part(body)
|
40
40
|
end
|
41
41
|
|
42
|
-
def
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
42
|
+
def initialize
|
43
|
+
@last_chunk_digest = nil # Digest OBJECT for last chunk (Digest::SHA256)
|
44
|
+
@last_chunk_digest_temp = nil # Digest VALUE for last chunk
|
45
|
+
@last_chunk_length = 0 # Length of last chunk, always smaller than 1MB.
|
46
|
+
@digest_stack = []
|
47
|
+
# First position on stack corresponds to 1MB, second 2MB, third 4MB, fourt 8MB and so on.
|
48
|
+
# In any time, the size of all already added parts is equal to sum of all existing (non-nil)
|
49
|
+
# positions multiplied by that number, plus last_chunk_length for the remainder smaller than
|
50
|
+
# one megabyte. So, if last_chunk_length is half megabyte, stack[0] is filled, stack[1] and
|
51
|
+
# stack[2] empty and stack[3] filled, the size is 0.5MB + 1x1MB + 0x2MB + 0x4MB + 1x8MB = 9.5MB.
|
52
|
+
end
|
53
|
+
|
54
|
+
def update_digest_stack(digest, stack)
|
55
|
+
stack.each_with_index{|s,i|
|
56
|
+
if s
|
57
|
+
digest = Digest::SHA256.digest(s + digest)
|
58
|
+
stack[i] = nil
|
59
|
+
else
|
60
|
+
stack[i] = digest # Update this position with value obtained in previous run of cycle.
|
61
|
+
digest = nil
|
62
|
+
break
|
50
63
|
end
|
51
|
-
|
52
|
-
|
64
|
+
}
|
65
|
+
stack << digest if digest
|
53
66
|
end
|
54
67
|
|
55
|
-
def
|
56
|
-
|
68
|
+
def reduce_digest_stack(digest, stack)
|
69
|
+
stack.each_with_index{|s,i|
|
70
|
+
unless digest
|
71
|
+
digest = stack[i]
|
72
|
+
next
|
73
|
+
end
|
74
|
+
if stack[i]
|
75
|
+
digest = Digest::SHA256.digest(stack[i] + digest)
|
76
|
+
end
|
77
|
+
}
|
78
|
+
digest
|
57
79
|
end
|
58
80
|
|
59
81
|
def add_part(bytes)
|
60
82
|
part = self.digest_for_part(bytes)
|
61
|
-
@digests << part
|
62
83
|
part.unpack('H*').first
|
63
84
|
end
|
64
85
|
|
65
|
-
def
|
66
|
-
chunk_count = [body.bytesize / MEGABYTE + (body.bytesize % MEGABYTE > 0 ? 1 : 0), 1].max
|
86
|
+
def prepare_body_for_slice(body)
|
67
87
|
if body.respond_to? :byteslice
|
68
|
-
|
88
|
+
r = yield(body, :byteslice)
|
69
89
|
else
|
70
90
|
if body.respond_to? :encoding
|
71
91
|
old_encoding = body.encoding
|
72
92
|
body.force_encoding('BINARY')
|
73
93
|
end
|
74
|
-
|
94
|
+
r = yield(body, :slice)
|
75
95
|
if body.respond_to? :encoding
|
76
96
|
body.force_encoding(old_encoding)
|
77
97
|
end
|
78
98
|
end
|
79
|
-
|
99
|
+
r
|
80
100
|
end
|
81
101
|
|
82
|
-
def
|
83
|
-
|
102
|
+
def digest_for_part(body)
|
103
|
+
part_stack = []
|
104
|
+
part_temp = nil
|
105
|
+
body_size = body.bytesize
|
106
|
+
prepare_body_for_slice(body) {|body, slice|
|
107
|
+
start_offset = 0
|
108
|
+
if @last_chunk_length != 0
|
109
|
+
start_offset = MEGABYTE - @last_chunk_length
|
110
|
+
@last_chunk_hash.update(body.send(slice, 0, start_offset))
|
111
|
+
hash = @last_chunk_hash.digest
|
112
|
+
@last_chunk_digest_temp = hash
|
113
|
+
if body_size > start_offset
|
114
|
+
@last_chunk_length = 0
|
115
|
+
@last_chunk_hash = nil
|
116
|
+
@last_chunk_digest_temp = nil
|
117
|
+
update_digest_stack(hash, @digest_stack)
|
118
|
+
else
|
119
|
+
part_temp = hash
|
120
|
+
@last_chunk_digest_temp = hash
|
121
|
+
@last_chunk_length += body_size
|
122
|
+
next
|
123
|
+
end
|
124
|
+
end
|
125
|
+
whole_chunk_count = (body_size - start_offset) / MEGABYTE
|
126
|
+
whole_chunk_count.times.each {|chunk_index|
|
127
|
+
hash = Digest::SHA256.digest(body.send(slice, start_offset + chunk_index * MEGABYTE, MEGABYTE))
|
128
|
+
update_digest_stack(hash, part_stack)
|
129
|
+
update_digest_stack(hash, @digest_stack)
|
130
|
+
}
|
131
|
+
rest_size = body_size - start_offset - whole_chunk_count * MEGABYTE
|
132
|
+
if rest_size > 0 || whole_chunk_count == 0
|
133
|
+
@last_chunk_hash = Digest::SHA256.new
|
134
|
+
@last_chunk_length = rest_size
|
135
|
+
@last_chunk_hash.update(body.send(slice, start_offset + whole_chunk_count * MEGABYTE, rest_size))
|
136
|
+
hash = @last_chunk_hash.digest
|
137
|
+
@last_chunk_digest_temp = hash
|
138
|
+
part_temp = hash
|
139
|
+
end
|
140
|
+
}
|
141
|
+
reduce_digest_stack(part_temp, part_stack)
|
84
142
|
end
|
85
143
|
|
86
144
|
def digest
|
87
|
-
|
145
|
+
reduce_digest_stack(@last_chunk_digest_temp, @digest_stack)
|
146
|
+
end
|
147
|
+
|
148
|
+
def hexdigest
|
149
|
+
digest.unpack('H*').first
|
88
150
|
end
|
89
151
|
end
|
90
152
|
|
data/lib/fog/aws/iam.rb
CHANGED
@@ -10,7 +10,7 @@ module Fog
|
|
10
10
|
class ValidationError < Fog::AWS::IAM::Error; end
|
11
11
|
|
12
12
|
requires :aws_access_key_id, :aws_secret_access_key
|
13
|
-
recognizes :host, :path, :port, :scheme, :persistent, :instrumentor, :instrumentor_name, :aws_session_token, :use_iam_profile, :aws_credentials_expire_at, :region
|
13
|
+
recognizes :host, :path, :port, :scheme, :persistent, :instrumentor, :instrumentor_name, :aws_session_token, :use_iam_profile, :aws_credentials_expire_at, :region, :sts_endpoint
|
14
14
|
|
15
15
|
request_path 'fog/aws/requests/iam'
|
16
16
|
request :add_user_to_group
|
data/lib/fog/aws/kinesis.rb
CHANGED
@@ -12,7 +12,7 @@ module Fog
|
|
12
12
|
class ProvisionedThroughputExceeded < Fog::Errors::Error; end
|
13
13
|
|
14
14
|
requires :aws_access_key_id, :aws_secret_access_key
|
15
|
-
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :instrumentor, :instrumentor_name
|
15
|
+
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :instrumentor, :instrumentor_name, :sts_endpoint
|
16
16
|
|
17
17
|
request_path 'fog/aws/requests/kinesis'
|
18
18
|
|
@@ -125,23 +125,26 @@ module Fog
|
|
125
125
|
end
|
126
126
|
|
127
127
|
class Mock
|
128
|
-
|
129
|
-
@mutex ||= Mutex.new
|
130
|
-
end
|
131
|
-
def mutex; self.class.mutex; end
|
128
|
+
@mutex = Mutex.new
|
132
129
|
|
133
130
|
def self.data
|
134
|
-
@
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
131
|
+
@mutex.synchronize do
|
132
|
+
@data ||= Hash.new do |hash, region|
|
133
|
+
hash[region] = Hash.new do |region_hash, key|
|
134
|
+
region_hash[key] = {
|
135
|
+
:kinesis_streams => {}
|
136
|
+
}
|
137
|
+
end
|
139
138
|
end
|
139
|
+
|
140
|
+
yield @data if block_given?
|
140
141
|
end
|
141
142
|
end
|
142
143
|
|
143
144
|
def self.reset
|
144
|
-
@
|
145
|
+
@mutex.synchronize do
|
146
|
+
@data = nil
|
147
|
+
end
|
145
148
|
end
|
146
149
|
|
147
150
|
def initialize(options={})
|
@@ -153,31 +156,36 @@ module Fog
|
|
153
156
|
end
|
154
157
|
|
155
158
|
def data
|
156
|
-
self.class.data
|
159
|
+
self.class.data do |data|
|
160
|
+
data[@region][@aws_access_key_id]
|
161
|
+
end
|
157
162
|
end
|
158
163
|
|
159
164
|
def reset_data
|
160
|
-
self.class.data
|
165
|
+
self.class.data do |data|
|
166
|
+
data[@region].delete(@aws_access_key_id)
|
167
|
+
end
|
161
168
|
end
|
162
169
|
|
163
170
|
def self.next_sequence_number
|
164
|
-
mutex.synchronize do
|
171
|
+
@mutex.synchronize do
|
165
172
|
@sequence_number ||= -1
|
166
173
|
@sequence_number += 1
|
167
174
|
@sequence_number.to_s
|
168
175
|
end
|
169
176
|
end
|
177
|
+
|
170
178
|
def next_sequence_number; self.class.next_sequence_number; end
|
171
179
|
|
172
180
|
def self.next_shard_id
|
173
|
-
mutex.synchronize do
|
181
|
+
@mutex.synchronize do
|
174
182
|
@shard_id ||= -1
|
175
183
|
@shard_id += 1
|
176
184
|
"shardId-#{@shard_id.to_s.rjust(12, "0")}"
|
177
185
|
end
|
178
186
|
end
|
187
|
+
|
179
188
|
def next_shard_id; self.class.next_shard_id; end
|
180
|
-
|
181
189
|
end
|
182
190
|
|
183
191
|
end
|
data/lib/fog/aws/kms.rb
CHANGED
@@ -14,7 +14,7 @@ module Fog
|
|
14
14
|
NotFoundException = Class.new(Fog::Errors::Error)
|
15
15
|
|
16
16
|
requires :aws_access_key_id, :aws_secret_access_key
|
17
|
-
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :instrumentor, :instrumentor_name
|
17
|
+
recognizes :region, :host, :path, :port, :scheme, :persistent, :use_iam_profile, :aws_session_token, :instrumentor, :instrumentor_name, :aws_credentials_expire_at, :sts_endpoint
|
18
18
|
|
19
19
|
request_path 'fog/aws/requests/kms'
|
20
20
|
request :list_keys
|
data/lib/fog/aws/lambda.rb
CHANGED
@@ -4,7 +4,7 @@ module Fog
|
|
4
4
|
extend Fog::AWS::CredentialFetcher::ServiceMethods
|
5
5
|
|
6
6
|
requires :aws_access_key_id, :aws_secret_access_key
|
7
|
-
recognizes :host, :path, :port, :scheme, :persistent, :region, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :version, :instrumentor, :instrumentor_name
|
7
|
+
recognizes :host, :path, :port, :scheme, :persistent, :region, :use_iam_profile, :aws_session_token, :aws_credentials_expire_at, :version, :instrumentor, :instrumentor_name, :sts_endpoint
|
8
8
|
|
9
9
|
request_path 'fog/aws/requests/lambda'
|
10
10
|
request :create_function
|