Documentation ¶
Overview ¶
package cfl provides a utility for interacting with CloudFlare
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Util ¶
type Util struct { Client *cloudflare.Client // contains filtered or unexported fields }
func (*Util) DestroyRecord ¶
func (util *Util) DestroyRecord(r *cloudflare.Record) error
func (*Util) EnsureRegistered ¶
func (util *Util) EnsureRegistered(name string, ip string, rec *cloudflare.Record) (*cloudflare.Record, bool, error)
Register ensures that a record with the given name and ip is registered and proxying (orange cloud enabled). An existing record can optionally be passed in, in which case the record is assumed to be registered and we enable the orange cloud for the existing record. EnsureRegistered returns:
- the record if registration was successful
- true of it was able to turn on proxying
- any error encountered
func (*Util) GetAllRecords ¶
func (util *Util) GetAllRecords() ([]cloudflare.Record, error)
Click to show internal directories.
Click to hide internal directories.