1. Packages
  2. Cloudflare
  3. Installation & Configuration
Cloudflare v5.31.0 published on Wednesday, Jun 12, 2024 by Pulumi

Cloudflare: Installation & Configuration

cloudflare logo
Cloudflare v5.31.0 published on Wednesday, Jun 12, 2024 by Pulumi

    The Pulumi Cloudflare provider uses the Cloudflare SDK to manage resources.

    Installation

    The Cloudflare provider is available as a package in all Pulumi languages:

    Configuring The Provider

    Pulumi relies on the Cloudflare SDK to authenticate requests from your computer to Cloudflare. Your credentials are never sent to pulumi.com. Once the credentials are obtained, there are two ways to communicate your configuration parameters to Pulumi:

    For authentication, you must use only one of: apiToken or apiKey/email. We recommend using apiToken.
    1. Set the environment variable CLOUDFLARE_API_TOKEN (or the legacy CLOUDFLARE_EMAIL and CLOUDFLARE_API_KEY):

      $ export CLOUDFLARE_API_TOKEN=YYYYYY
      # Legacy
      $ export CLOUDFLARE_EMAIL=XXXXXX
      $ export CLOUDFLARE_API_KEY=YYYYYY
      
    2. If you prefer that they be stored alongside your Pulumi stack for easy multi-user access:

      $ pulumi config set cloudflare:apiToken --secret
      # Legacy
      $ pulumi config set cloudflare:email XXXXXX
      $ pulumi config set cloudflare:apiKey YYYYYY --secret
      

    The complete list of configuration parameters is in the Cloudflare provider README.

    cloudflare logo
    Cloudflare v5.31.0 published on Wednesday, Jun 12, 2024 by Pulumi