socket

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2026 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package socket connects apps and runners over Unix sockets using HTTP/2 without TLS.

Index

Constants

View Source
const BaseURL = "http://runner"

BaseURL is the base URL for clients returned by Client; the host part is ignored.

Variables

This section is empty.

Functions

func Client

func Client(path string) *http.Client

Client returns an HTTP/2 client that dials the Unix socket at path.

func Listen

func Listen(ctx context.Context, path string) (net.Listener, error)

Listen creates a Unix socket at path that only its owner can use, replacing a stale one.

func NewServer

func NewServer(h http.Handler) *http.Server

NewServer returns a server for h that speaks HTTP/1.1 and HTTP/2 without TLS and has timeouts set. A stream that moves in neither direction for 60 seconds is cut; one that keeps moving may run as long as it needs.

Types

This section is empty.

Jump to

Keyboard shortcuts

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