项目作者: JamesWoolfenden

项目描述 :
Basic Disk module
高级语言: Makefile
项目地址: git://github.com/JamesWoolfenden/terraform-azurerm-disk.git
创建时间: 2021-02-16T21:55:41Z
项目社区:https://github.com/JamesWoolfenden/terraform-azurerm-disk

开源协议:Apache License 2.0

下载


terraform-azurerm-disk

Build Status
Latest Release
GitHub tag (latest SemVer)
Terraform Version
Infrastructure Tests
pre-commit
checkov
Infrastructure Tests

Terraform module -


It’s 100% Open Source and licensed under the APACHE2.

Usage

This is just a very basic example.

Include module.disk.tf this repository as a module in your existing terraform code:

  1. module "disk" {
  2. source = "JamesWoolfenden/disk/azurerm"
  3. common_tags = var.common_tags
  4. resource_group_name = var.resource_group_name
  5. disk_name = var.disk_name
  6. }

Requirements

No requirements.

Providers

Name Version
azurerm n/a

Modules

No modules.

Resources

Name Type
azurerm_managed_disk.example resource

Inputs

Name Description Type Default Required
common_tags This is to help you add tags to your cloud objects map(any) n/a yes
disk_encryption_set_id set id of managed disk encryption set string n/a yes
disk_name n/a string n/a yes
disk_size_gb n/a number 10 no
location n/a string n/a yes
network_access_policy n/a string "DenyAll" no
resource_group_name n/a string n/a yes
storage_account_type n/a string "Standard_LRS" no

Outputs

Name Description
disk n/a

Policy

This is the policy required to build this project:

The Terraform resource required is:

  1. resource "azurerm_role_definition" "terraform_pike" {
  2. role_definition_id = local.uuid
  3. name = "terraform_pike"
  4. scope = data.azurerm_subscription.primary.id
  5. permissions {
  6. actions = [
  7. "Microsoft.Compute/disks/delete",
  8. "Microsoft.Compute/disks/read",
  9. "Microsoft.Compute/disks/write",
  10. "Microsoft.Resources/subscriptions/resourcegroups/read"]
  11. not_actions = []
  12. }
  13. assignable_scopes = [
  14. data.azurerm_subscription.primary.id,
  15. ]
  16. }
  17. locals {
  18. uuid = uuid()
  19. }
  20. data "azurerm_subscription" "primary" {
  21. }

Check out these related projects.

Help

Got a question?

File a GitHub issue.

Contributing

Bug Reports & Feature Requests

Please use the issue tracker to report any bugs or file feature requests.

Copyrights

Copyright © 2019-2023 James Woolfenden

License

License

See LICENSE for full details.

Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
“License”); you may not use this file except in compliance
with the License. You may obtain a copy of the License at

https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
“AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.

Contributors

James Woolfenden
James Woolfenden