client

package
v1.4.15 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 31, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Implements an API client for the nginx API (https://github.com/mutablelogic/go-server/pkg/handler/nginx)

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	*client.Client
}

func New

func New(endPoint string, opts ...client.ClientOpt) (*Client, error)

Create a new API client, providing the endpoint (ie, http://example.com/api/nginx)

func (*Client) Health

func (c *Client) Health() (string, time.Duration, error)

Return health of the API - nginx version, uptime

func (*Client) Reload

func (c *Client) Reload() error

Reload the nginx configuration

func (*Client) Reopen

func (c *Client) Reopen() error

Reopen the log files (after rotation)

func (*Client) Test

func (c *Client) Test() error

Test the configuration

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL