Skip to content
This repository has been archived by the owner on Apr 8, 2022. It is now read-only.
/ hostnamesapi Public archive

JavaScript examples for working with the new hostnames API on Fly

License

Notifications You must be signed in to change notification settings

fly-apps/hostnamesapi

Repository files navigation

Hostnames API (hostnamesapi)

JavaScript examples for working with the new hostnames API on Fly

To use

  • Download/Clone this repository
  • Run npm install for required packages
  • Set FLY_API_TOKEN environment variable to an API token acquired from fly.io (Dashboard -> Account -> Settings -> Access Tokens -> Create Access Token)
  • Run node appname --help for details of required arguments.

e.g.

❯ node getcert -a hellofly -h hellofly.fly.dev
{
  "app": {
    "certificate": {
      "acmeDnsConfigured": true,
      "certificateAuthority": "lets_encrypt",
      "createdAt": "2020-01-17T16:51:24Z",
      "dnsProvider": "dnsimple",
      "dnsValidationInstructions": "CNAME _acme-challenge.hellofly.fly.dev => hellofly.fly.dev.x6dr.flydns.net.",
      "dnsValidationHostname": "_acme-challenge.hellofly.fly.dev",
      "dnsValidationTarget": "hellofly.fly.dev.x6dr.flydns.net",
      "hostname": "hellofly.fly.dev",
      "id": "3AzsPZI7QiZ0HB6FeZTJjU69iR2C56Sq4uBvhjxiQ7hBY",
      "source": "fly",
      "clientStatus": "Ready",
      "issued": {
        "nodes": [
          {
            "type": "ecdsa",
            "expiresAt": "2020-04-16T16:04:19Z"
          },
          {
            "type": "rsa",
            "expiresAt": "2020-04-16T16:04:08Z"
          }
        ]
      }
    }
  }
}

About

JavaScript examples for working with the new hostnames API on Fly

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published