gnatips

package module
v0.0.0-...-f847f60 Latest Latest
Warning

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

Go to latest
Published: Aug 22, 2023 License: MIT Imports: 4 Imported by: 1

README

gnatips-go

A tiny convenience package to get NAT ips from a region of a particular GCP project.

I wanted a nice very simple package to do this and didn't see one.

ctx, cancel := context.WithTimeout(ctx, 3*time.Second)
defer cancel()
ips, err := gnatips.Get(ctx, "project-name-goes-here", "us-west2")
if err != nil {
    // Do something.
}
// ips: ["127.0.0.1", "8.8.8.8", "1.1.1.1"]

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Get

func Get(ctx context.Context, project, region string) ([]string, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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