Giter Site home page Giter Site logo

ibm-cloud-provider-for-terraform's Introduction

ibm-cloud-provider-for-terraform's People

Contributors

alchemydocs avatar cldocid2 avatar derekpoindexter avatar geethasathyamurthy avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

ibm-cloud-provider-for-terraform's Issues

`ibm_is_vpn_gateway_connection` input variables `local_cidrs` and `peer_cidrs` are not optional

Issue
Document states ibm_is_vpn_gateway_connection resource variables local_cidrs and peer_cidrs are optional, but if you try to apply a GW connection without those variables, it fails to create resource.

Document: https://cloud.ibm.com/docs/terraform?topic=terraform-vpc-gen2-resources#vpn-gateway-connection

Error Message

Error: [DEBUG] Create VPN Gateway Connection err At least one local CIDR block is required when creating a VPN connection.

Steps to Recreate

resource "ibm_is_vpn_gateway_connection" "this" {
    name = "vpn-gw-test"
    admin_state_up = true
    vpn_gateway = ibm_is_vpn_gateway.this.id
    peer_address = var.peer_address
    preshared_key = var.preshared_key
}

Expect
If its optional then it should create without error

VPC Gen2 volume example is failing with an error.

The first volume example fails :
https://cloud.ibm.com/docs/terraform?topic=terraform-vpc-gen2-resources#volume-sample

resource "ibm_is_volume" "testacc_volume" {
  name     = "test_volume"
  profile  = "10iops-tier"
  zone     = "us-south-1"
  iops     = 10000
  capacity = 100
}

The output result when trying to use this configuration is :

    "Result": {
        "errors": [
            {
                "code": "volume_profile_iops_invalid",
                "message": "The volume profile specified in the request cannot accept custom IOPS.",
                "more_info": "http://www.bluemix.com/help#volume_profile_iops_invalid",
                "target": {
                    "name": "",
                    "type": ""
                }
            }
        ],
        "trace": "d24e832407bb66c67ef776551c5bae6b"
    },

Removing the iops options from the definition allows the example to pass.

ibm_is_subnet input parameter required not optional?

Re: https://cloud.ibm.com/docs/ibm-cloud-provider-for-terraform?topic=ibm-cloud-provider-for-terraform-vpc-gen2-data-sources#vpc-subnet-input

Hi,

It appears vpc-subnet-input requires "identifier" though the document states its an optional. I'm getting below error.

Error: Missing required argument

  on create-testnet-v2.tf line 16, in data "ibm_is_subnet" "subnet1":
  16: data "ibm_is_subnet"        "subnet1"     { name = "${var.resource_group}-${var.zone}-sn" }

The argument "identifier" is required, but no definition was found.

Also, it would be really helpful to get the subnet information by name only. is that possible any other way for now?

Terraform IBM Cloud provider set up

for version 0.13 you need not download any plugin
You can directly run your template
having this in versions.tf file
terraform {
required_providers {
ibm = {
source = "IBM-Cloud/ibm"
version = "1.11.2"
}
}
}
Place versions.tf and your template file under same directory

The default value of disable_public_service_endpoint is false instead of true

Currently we have the input parameter disable_public_service_endpoint for resource ibm_container_vpc_cluster documented as:

disable_public_service_endpoint - (Optional,Bool) Disable the public service endpoint to prevent public access to the master. Default Value 'true'.

The code, on the master branch, reveals the default is false:

			"disable_public_service_endpoint": {
				Type:        schema.TypeBool,
				Optional:    true,
				Default:     false,
				Description: "Boolean value true if Public service endpoint to be disabled",

Docs must be aligned with the code.

Error: Error occured while fetching account user details: "token contains an invalid number of segments"

I noticed the error below when I ran "terraform plan". I had no issue on "terraform init"

Can anyone guide me what should I modify?

  • terraform version: v0.15.5
    Terraform v0.15.5
    on darwin_amd64
  • provider registry.terraform.io/ibm-cloud/ibm v1.26.0

Error: Error occured while fetching account user details: "token contains an invalid number of segments"

│ with data.ibm_is_image.centos,
│ on vpc.tf line 37, in data "ibm_is_image" "centos":
│ 37: data ibm_is_image "centos" {



│ Error: Error occured while fetching account user details: "token contains an invalid number of segments"

│ with data.ibm_is_ssh_key.ssh_key_id,
│ on vpc.tf line 41, in data "ibm_is_ssh_key" "ssh_key_id":
│ 41: data ibm_is_ssh_key "ssh_key_id" {

terraform - Provisioning an IBM Cloud virtual server for VPC

https://cloud.ibm.com/docs/ibm-cloud-provider-for-terraform?topic=ibm-cloud-provider-for-terraform-sample_vpc_config

image

this is an odd way to initialize a provider and does not specify a region.
Setting TF_LOG=debug is not recommended for normal use.

The example source code should not include the steps above. Instead add the following to the top fo the vpc.tf file:

variable ibmcloud_api_key {}

provider "ibm" {
  ibmcloud_api_key = var.ibmcloud_api_key
  region           = "us-south" # this could come from a variable as well, it will need to match the ZONE variable used
}

Then instruct the user to:

export TF_VAR_ibmcloud_api_key="VoeEd1231231234134123413"

How to avoid conflicting error of deleting a resource if it has different types of attachments.

I have noticed that "depend_on" needs to be added to avoid conflicting update error if a resource has different types of attachments.

For example, terraform code I used
resource "ibm_is_instance_volume_attachment" "iac_attach_app_volume" {

#depends_on = [ ibm_is_floating_ip.iac_test_floating_ip ]

count = var.home_fs_size > 0 ? 1 : 0
instance = ibm_is_instance.iac_test_instance.id
name = "${var.project_name}-${var.environment}-volume-01-att"
volume = ibm_is_volume.iac_app_volume[0].id

If the "depends_on" is not applied, the following error occurs when I tried to destroy it.

ibm_is_instance_volume_attachment.iac_attach_app_volume[0]: Destroying... [id=0717_1a3fbc00-807b-4d01-9590-814ccfb61a05/0717-abdd070e-f2bd-4a7f-8690-8a1702b9563c]
ibm_is_security_group_rule.iac_test_security_group_rule_tcp_ssh: Destroying... [id=r006-a7d3d85e-066b-45b5-931f-440d2bee64fb.r006-e444f91b-2a3f-4a94-bda8-38a8a783539f]
ibm_is_security_group_rule.iac_test_security_group_rule_all_outbound: Destruction complete after 2s
ibm_is_security_group_rule.iac_test_security_group_rule_tcp_ssh: Destruction complete after 3s
ibm_is_floating_ip.iac_test_floating_ip: Still destroying... [id=r006-a2fc0299-b709-4aad-baf2-36cdd051e015, 10s elapsed]
ibm_is_floating_ip.iac_test_floating_ip: Destruction complete after 12s

│ Error: Error while deleting volume attachment (0717-abdd070e-f2bd-4a7f-8690-8a1702b9563c) from instance (0717_1a3fbc00-807b-4d01-9590-814ccfb61a05) : "Conflicting update of instance, please retry request"

I also discussed it to get an advise at "terraform-ibmcloud-users" slack channel.

Confusing add-ons listing for Kubernetes Service

The list of example add-ons for the ibm_container_addons:

https://cloud.ibm.com/docs/ibm-cloud-provider-for-terraform?topic=ibm-cloud-provider-for-terraform-container-resources#container-addons-input

seems to include options that are applicable to IKS , and does not indicate that some, like knative are not a supported add-on for ROKS:

https://cloud.ibm.com/docs/openshift?topic=openshift-managed-addons#adding-managed-add-ons

This was noted by a business partner trying to configure Knative for their ROKS cluster created with the terraform provider. They've switched to the OpenShift Serverless Operator.

Please make clear if Terraform issues occur outside of Schematics, to engage Terraform IBM Provider rather than IBM Cloud support

Customers are sometimes confused by the multiple support avenues provided in this page. If the issue is with an API call outside of Terraform, that would be an IBM Cloud support issue for which a support case can be opened. If the issue is with a Schematics job fails while running a Terraform apply, that too would be an IBM Cloud support issue for which a support case can be opened.

However, if the issue occurs when customer uses Terraform outside of Schematics, and the API calls in that Terraform apply work when run outside of Terraform, then the issue should be taken to the github space for the Terraform IBM Provider.

Get errors

Hello,

I am not a developer but have modified terraform code in the past. Therefore I wanted to execute the procedure from scratch.

Step2- point1 It would be nice to suggest a file name e.g. kubernetes.tf
Not clear if we create either Kubernetes or ROKS or both

Point 2: terraform init worked

Point 3: terraform plan throws errors

Gets the following errors: Can you provide a sample config where you only define the API-Key by an env variable and then have a configuration that works.

Warning: Value for undeclared variable

│ The root module does not declare a variable named "ibmcloud_api_key" but a
│ value was found in file "terraform.tfvars". If you meant to use this value,
│ add a "variable" block to the configuration.

│ To silence these warnings, use TF_VAR_... environment variables to provide
│ certain "global" settings to all configurations in your organization. To
│ reduce the verbosity of these warnings, use the -compact-warnings option.


│ Error: ibmcloud_api_key or bluemix_api_key or iam_token and iam_refresh_token must be provided. Please see the documentation on how to configure it

│ with data.ibm_resource_group.resource_group,
│ on kub.tf line 1, in data "ibm_resource_group" "resource_group":
│ 1: data ibm_resource_group "resource_group" {

I will talk to a developer, propably this can be fixed but maybe we can support a newby by more detailed steps.

Happy to volunteer for trying it out.

Instructions are not correct for Terraform 0.13

Hello, the instructions on this page (https://cloud.ibm.com/docs/terraform?topic=terraform-getting-started) will not work for the latest version of terraform. Instead, the entire zip file must be placed in a specific directory - not the unzipped version.

My personal installation is working, but I would suggest you revise the document to reflect the new process. Alternatively, it would be far simpler for users if you simply published the provider to the Terraform registry. Just a thought.

Sample script does not work

Sample script provided to create a VM does not work as item is no longer available:
Error: [ERROR] Error ordering virtual guest: SoftLayer_Exception_Order_Item_Unavailable: Debian GNU/Linux 8.x jessie/Stable - Minimal Install (64 bit) is not available as of 09/12/2020 (Item #(6195). (HTTP 500)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.