Files
opentf/website/source/docs/providers/scaleway/index.html.markdown
Ollie Ford ed2b959f7e Fix contradiction in terms with provider documentation (#10815) (#10874)
* Remove contradiction with Scaleway documentation

The parameters previously termed by Terraform:

1. Organization
2. Access key

Are referred to, respectively, by Scaleway [0] as:

1. Access key
2. Token

which is a confusing contradiction for a user.

Since Scaleway terms (1) both 'access key' [0] and 'organization ID' [1],
@nicolai86 suggested keeping the latter as already used, but changing (2) for
'token'; removing the contradiction.

This commit thus changes the parameters to:

1. Organization
2. Token

Closes #10815.

[0] - https://cloud.scaleway.com/#/credentials
[1] - https://www.scaleway.com/docs/retrieve-my-organization-id-throught-the-api

* Update docs to reflect Scaleway offering x86

Scaleway now provides x86 servers [0] as well as ARM.

This commit removes 'ARM' from various references suggesting that might be the
only option.

[0] - https://blog.online.net/2016/03/08/c2-insanely-affordable-x64-servers/
2017-01-17 12:02:55 +00:00

2.1 KiB

layout, page_title, sidebar_current, description
layout page_title sidebar_current description
scaleway Provider: Scaleway docs-scaleway-index The Scaleway provider is used to interact with Scaleway bare metal & VPS provider.

Scaleway Provider

The Scaleway provider is used to manage Scaleway resources.

Use the navigation to the left to read about the available resources.

Example Usage

Here is an example that will setup the following:

  • An ARM Server.
  • An IP Address.
  • A security group.

(create this as sl.tf and run terraform commands from this directory):

provider "scaleway" {
  organization = ""
  access_key = ""
  region = "par1"
}

resource "scaleway_ip" "ip" {
  server = "${scaleway_server.test.id}"
}

resource "scaleway_server" "test" {
  name = "test"
  image = "aecaed73-51a5-4439-a127-6d8229847145"
  type = "C2S"
}

resource "scaleway_volume" "test" {
  name = "test"
  size_in_gb = 20
  type = "l_ssd"
}

resource "scaleway_volume_attachment" "test" {
  server = "${scaleway_server.test.id}"
  volume = "${scaleway_volume.test.id}"
}

resource "scaleway_security_group" "http" {
  name = "http"
  description = "allow HTTP and HTTPS traffic"
}

resource "scaleway_security_group_rule" "http_accept" {
  security_group = "${scaleway_security_group.http.id}"

  action = "accept"
  direction = "inbound"
  ip_range = "0.0.0.0/0"
  protocol = "TCP"
  port = 80
}

resource "scaleway_security_group_rule" "https_accept" {
  security_group = "${scaleway_security_group.http.id}"

  action = "accept"
  direction = "inbound"
  ip_range = "0.0.0.0/0"
  protocol = "TCP"
  port = 443
}

You'll need to provide your Scaleway organization access key (available in Scaleway panel in Credentials > Tokens > access key) and token (you can generate it in the same section), so that Terraform can connect. If you don't want to put credentials in your configuration file, you can leave them out:

provider "scaleway" {
  organization = ""
  token = ""
  region = "par1"
}

...and instead set these environment variables:

  • SCALEWAY_ORGANIZATION: Your Scaleway organization access key
  • SCALEWAY_TOKEN: Your API access token
  • SCALEWAY_REGION: The Scaleway region