repo stringlengths 6 47 | file_url stringlengths 77 269 | file_path stringlengths 5 186 | content stringlengths 0 32.8k | language stringclasses 1
value | license stringclasses 7
values | commit_sha stringlengths 40 40 | retrieved_at stringdate 2026-01-07 08:35:43 2026-01-07 08:55:24 | truncated bool 2
classes |
|---|---|---|---|---|---|---|---|---|
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/sysinfo/sysinfo_other.go | pkg/sysinfo/sysinfo_other.go | //go:build !linux
package sysinfo
// New returns an empty SysInfo for non linux for now.
func New(options ...Opt) *SysInfo {
return &SysInfo{}
}
func isCpusetListAvailable(string, map[int]struct{}) (bool, error) {
return false, nil
}
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/sysinfo/cgroup2_linux.go | pkg/sysinfo/cgroup2_linux.go | package sysinfo
import (
"context"
"os"
"path"
"strings"
"github.com/containerd/cgroups/v3"
cgroupsV2 "github.com/containerd/cgroups/v3/cgroup2"
"github.com/containerd/log"
"github.com/moby/sys/userns"
)
func newV2(options ...Opt) *SysInfo {
sysInfo := &SysInfo{
CgroupUnified: true,
cg2GroupPath: "/",
... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/kernel/kernel_darwin.go | pkg/parsers/kernel/kernel_darwin.go | //go:build darwin
// Package kernel provides helper function to get, parse and compare kernel
// versions for different platforms.
package kernel
import (
"fmt"
"os/exec"
"strings"
)
// GetKernelVersion gets the current kernel version.
func GetKernelVersion() (*VersionInfo, error) {
osName, err := getSPSoftwareD... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/kernel/kernel_darwin_test.go | pkg/parsers/kernel/kernel_darwin_test.go | package kernel
import (
"testing"
"gotest.tools/v3/assert"
)
func TestGetRelease(t *testing.T) {
// example output of "system_profiler SPSoftwareDataType"
const spSoftwareDataType = `Software:
System Software Overview:
System Version: macOS 10.14.6 (18G4032)
Kernel Version: Darwin 18.7.0
... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/kernel/kernel_unix_test.go | pkg/parsers/kernel/kernel_unix_test.go | //go:build !windows
package kernel
import (
"fmt"
"testing"
)
func assertParseRelease(t *testing.T, release string, b *VersionInfo, result int) {
var a *VersionInfo
a, _ = ParseRelease(release)
if r := CompareKernelVersion(*a, *b); r != result {
t.Fatalf("Unexpected kernel version comparison result for (%v,%... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/kernel/uname_linux.go | pkg/parsers/kernel/uname_linux.go | package kernel
import "golang.org/x/sys/unix"
func uname() (*unix.Utsname, error) {
uts := &unix.Utsname{}
if err := unix.Uname(uts); err != nil {
return nil, err
}
return uts, nil
}
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/kernel/kernel_windows.go | pkg/parsers/kernel/kernel_windows.go | package kernel
import (
"fmt"
"golang.org/x/sys/windows"
"golang.org/x/sys/windows/registry"
)
// VersionInfo holds information about the kernel.
type VersionInfo struct {
kvi string // Version of the kernel (e.g. 6.1.7601.17592 -> 6)
major int // Major part of the kernel version (e.g. 6.1.7601.17592 -> 1)... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/kernel/kernel.go | pkg/parsers/kernel/kernel.go | //go:build !windows
// Package kernel provides helper function to get, parse and compare kernel
// versions for different platforms.
package kernel
import (
"errors"
"fmt"
)
// VersionInfo holds information about the kernel.
type VersionInfo struct {
Kernel int // Version of the kernel (e.g. 4.1.2-generic -> 4... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/kernel/kernel_unix.go | pkg/parsers/kernel/kernel_unix.go | //go:build linux || freebsd || openbsd
package kernel
import (
"context"
"github.com/containerd/log"
"golang.org/x/sys/unix"
)
// GetKernelVersion gets the current kernel version.
func GetKernelVersion() (*VersionInfo, error) {
uts, err := uname()
if err != nil {
return nil, err
}
// Remove the \x00 from ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/kernel/uname_unsupported.go | pkg/parsers/kernel/uname_unsupported.go | //go:build !linux
package kernel
import (
"errors"
)
// utsName represents the system name structure. It is defined here to make it
// portable as it is available on Linux but not on Windows.
type utsName struct {
Release [65]byte
}
func uname() (*utsName, error) {
return nil, errors.New("kernel version detectio... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/operatingsystem/windows_os_string_test.go | pkg/parsers/operatingsystem/windows_os_string_test.go | package operatingsystem
import (
"testing"
)
func Test_windowsOSRelease_String(t *testing.T) {
tests := []struct {
name string
r windowsOSRelease
want string
}{
{
name: "Flavor=client/DisplayVersion=yes/UBR=yes",
r: windowsOSRelease{
DisplayVersion: "1809",
Build: 17763,
UBR: ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/operatingsystem/operatingsystem_unix.go | pkg/parsers/operatingsystem/operatingsystem_unix.go | //go:build freebsd || darwin
package operatingsystem
import (
"errors"
"golang.org/x/sys/unix"
)
// GetOperatingSystem gets the name of the current operating system.
func GetOperatingSystem() (string, error) {
utsname := &unix.Utsname{}
if err := unix.Uname(utsname); err != nil {
return "", err
}
return uni... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/operatingsystem/windows_os_string.go | pkg/parsers/operatingsystem/windows_os_string.go | package operatingsystem
import (
"fmt"
"strings"
)
type windowsOSRelease struct {
IsServer bool
DisplayVersion string
Build uint32
UBR uint64
}
// String formats the OS release data similar to what is displayed by
// winver.exe.
func (r *windowsOSRelease) String() string {
var b stri... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/operatingsystem/operatingsystem_linux.go | pkg/parsers/operatingsystem/operatingsystem_linux.go | // Package operatingsystem provides helper function to get the operating system
// name for different platforms.
package operatingsystem
import (
"bufio"
"bytes"
"os"
"strings"
)
var (
// file to use to detect if the daemon is running in a container
proc1Cgroup = "/proc/1/cgroup"
// file to check to determine... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/operatingsystem/operatingsystem_windows.go | pkg/parsers/operatingsystem/operatingsystem_windows.go | package operatingsystem
import (
"errors"
"github.com/Microsoft/hcsshim/osversion"
"golang.org/x/sys/windows"
"golang.org/x/sys/windows/registry"
)
// VER_NT_WORKSTATION, see https://docs.microsoft.com/en-us/windows/win32/api/winnt/ns-winnt-osversioninfoexa
const verNTWorkstation = 0x00000001 // VER_NT_WORKSTATI... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/pkg/parsers/operatingsystem/operatingsystem_linux_test.go | pkg/parsers/operatingsystem/operatingsystem_linux_test.go | //go:build linux || freebsd
package operatingsystem
import (
"os"
"path/filepath"
"testing"
"gotest.tools/v3/assert"
)
type EtcReleaseParsingTest struct {
name string
content string
expected string
expectedErr string
}
func TestGetOperatingSystem(t *testing.T) {
tests := []EtcReleaseParsingT... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/tools.go | man/tools.go | //go:build tools
package man
import (
_ "github.com/cpuguy83/go-md2man/v2"
)
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/cpuguy83/go-md2man/v2/md2man.go | man/vendor/github.com/cpuguy83/go-md2man/v2/md2man.go | package main
import (
"flag"
"fmt"
"io/ioutil"
"os"
"github.com/cpuguy83/go-md2man/v2/md2man"
)
var (
inFilePath = flag.String("in", "", "Path to file to be processed (default: stdin)")
outFilePath = flag.String("out", "", "Path to output processed file (default: stdout)")
)
func main() {
var err error
fl... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/cpuguy83/go-md2man/v2/md2man/roff.go | man/vendor/github.com/cpuguy83/go-md2man/v2/md2man/roff.go | package md2man
import (
"bufio"
"bytes"
"fmt"
"io"
"os"
"strings"
"github.com/russross/blackfriday/v2"
)
// roffRenderer implements the blackfriday.Renderer interface for creating
// roff format (manpages) from markdown text
type roffRenderer struct {
listCounters []int
firstHeader bool
listDepth int
}... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/cpuguy83/go-md2man/v2/md2man/debug.go | man/vendor/github.com/cpuguy83/go-md2man/v2/md2man/debug.go | package md2man
import (
"fmt"
"io"
"os"
"strings"
"github.com/russross/blackfriday/v2"
)
func fmtListFlags(flags blackfriday.ListType) string {
knownFlags := []struct {
name string
flag blackfriday.ListType
}{
{"ListTypeOrdered", blackfriday.ListTypeOrdered},
{"ListTypeDefinition", blackfriday.ListTyp... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/cpuguy83/go-md2man/v2/md2man/md2man.go | man/vendor/github.com/cpuguy83/go-md2man/v2/md2man/md2man.go | // Package md2man aims in converting markdown into roff (man pages).
package md2man
import (
"os"
"strconv"
"github.com/russross/blackfriday/v2"
)
// Render converts a markdown document into a roff formatted document.
func Render(doc []byte) []byte {
renderer := NewRoffRenderer()
var r blackfriday.Renderer = re... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/russross/blackfriday/v2/block.go | man/vendor/github.com/russross/blackfriday/v2/block.go | //
// Blackfriday Markdown Processor
// Available at http://github.com/russross/blackfriday
//
// Copyright © 2011 Russ Ross <russ@russross.com>.
// Distributed under the Simplified BSD License.
// See README.md for details.
//
//
// Functions to parse block-level elements.
//
package blackfriday
import (
"bytes"
... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | true |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/russross/blackfriday/v2/node.go | man/vendor/github.com/russross/blackfriday/v2/node.go | package blackfriday
import (
"bytes"
"fmt"
)
// NodeType specifies a type of a single node of a syntax tree. Usually one
// node (and its type) corresponds to a single markdown feature, e.g. emphasis
// or code block.
type NodeType int
// Constants for identifying different types of nodes. See NodeType.
const (
D... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/russross/blackfriday/v2/entities.go | man/vendor/github.com/russross/blackfriday/v2/entities.go | package blackfriday
// Extracted from https://html.spec.whatwg.org/multipage/entities.json
var entities = map[string]bool{
"Æ": true,
"Æ": true,
"&": true,
"&": true,
"Á": ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | true |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/russross/blackfriday/v2/esc.go | man/vendor/github.com/russross/blackfriday/v2/esc.go | package blackfriday
import (
"html"
"io"
)
var htmlEscaper = [256][]byte{
'&': []byte("&"),
'<': []byte("<"),
'>': []byte(">"),
'"': []byte("""),
}
func escapeHTML(w io.Writer, s []byte) {
escapeEntities(w, s, false)
}
func escapeAllHTML(w io.Writer, s []byte) {
escapeEntities(w, s, true)
}
... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/russross/blackfriday/v2/html.go | man/vendor/github.com/russross/blackfriday/v2/html.go | //
// Blackfriday Markdown Processor
// Available at http://github.com/russross/blackfriday
//
// Copyright © 2011 Russ Ross <russ@russross.com>.
// Distributed under the Simplified BSD License.
// See README.md for details.
//
//
//
// HTML rendering backend
//
//
package blackfriday
import (
"bytes"
"fmt"
"io"
... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/russross/blackfriday/v2/inline.go | man/vendor/github.com/russross/blackfriday/v2/inline.go | //
// Blackfriday Markdown Processor
// Available at http://github.com/russross/blackfriday
//
// Copyright © 2011 Russ Ross <russ@russross.com>.
// Distributed under the Simplified BSD License.
// See README.md for details.
//
//
// Functions to parse inline elements.
//
package blackfriday
import (
"bytes"
"rege... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/russross/blackfriday/v2/doc.go | man/vendor/github.com/russross/blackfriday/v2/doc.go | // Package blackfriday is a markdown processor.
//
// It translates plain text with simple formatting rules into an AST, which can
// then be further processed to HTML (provided by Blackfriday itself) or other
// formats (provided by the community).
//
// The simplest way to invoke Blackfriday is to call the Run functi... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/russross/blackfriday/v2/smartypants.go | man/vendor/github.com/russross/blackfriday/v2/smartypants.go | //
// Blackfriday Markdown Processor
// Available at http://github.com/russross/blackfriday
//
// Copyright © 2011 Russ Ross <russ@russross.com>.
// Distributed under the Simplified BSD License.
// See README.md for details.
//
//
//
// SmartyPants rendering
//
//
package blackfriday
import (
"bytes"
"io"
)
// SP... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/man/vendor/github.com/russross/blackfriday/v2/markdown.go | man/vendor/github.com/russross/blackfriday/v2/markdown.go | // Blackfriday Markdown Processor
// Available at http://github.com/russross/blackfriday
//
// Copyright © 2011 Russ Ross <russ@russross.com>.
// Distributed under the Simplified BSD License.
// See README.md for details.
package blackfriday
import (
"bytes"
"fmt"
"io"
"strings"
"unicode/utf8"
)
//
// Markdown ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/cmd/docker-proxy/proxy_linux.go | cmd/docker-proxy/proxy_linux.go | // docker-proxy provides a network Proxy interface and implementations for TCP
// and UDP.
package main
// ipVersion refers to IP version - v4 or v6
type ipVersion string
const (
// IPv4 is version 4
ip4 ipVersion = "4"
// IPv6 is version 6
ip6 ipVersion = "6"
)
// Proxy defines the behavior of a proxy. It forwa... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/cmd/docker-proxy/udp_proxy_linux_test.go | cmd/docker-proxy/udp_proxy_linux_test.go | package main
import (
"net"
"testing"
"time"
"gotest.tools/v3/assert"
)
// TestUDPOneSided makes sure that the conntrack entry isn't GC'd if the
// backend never writes to the UDP client.
func TestUDPOneSided(t *testing.T) {
frontend, err := net.ListenUDP("udp", &net.UDPAddr{IP: net.IPv4(127, 0, 0, 1), Port: 0}... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/cmd/docker-proxy/sctp_proxy_linux.go | cmd/docker-proxy/sctp_proxy_linux.go | package main
import (
"io"
"log"
"net"
"sync"
"github.com/ishidawataru/sctp"
)
// SCTPProxy is a proxy for SCTP connections. It implements the Proxy interface to
// handle SCTP traffic forwarding between the frontend and backend addresses.
type SCTPProxy struct {
listener *sctp.SCTPListener
frontendAddr *... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/cmd/docker-proxy/tcp_proxy_linux.go | cmd/docker-proxy/tcp_proxy_linux.go | package main
import (
"io"
"log"
"net"
"sync"
)
// TCPProxy is a proxy for TCP connections. It implements the Proxy interface to
// handle TCP traffic forwarding between the frontend and backend addresses.
type TCPProxy struct {
listener *net.TCPListener
frontendAddr *net.TCPAddr
backendAddr *net.TCPAddr
... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/cmd/docker-proxy/main_linux.go | cmd/docker-proxy/main_linux.go | package main
import (
"flag"
"fmt"
"net"
"os"
"os/signal"
"syscall"
"github.com/ishidawataru/sctp"
"github.com/moby/moby/v2/dockerversion"
"golang.org/x/net/ipv4"
"golang.org/x/net/ipv6"
)
// The caller is expected to pass-in open file descriptors ...
const (
// Pipe for reporting status, as a string. "0\... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/cmd/docker-proxy/network_proxy_linux_test.go | cmd/docker-proxy/network_proxy_linux_test.go | //go:build !windows
package main
import (
"bytes"
"fmt"
"io"
"net"
"os"
"strings"
"testing"
"time"
"github.com/ishidawataru/sctp"
"golang.org/x/sys/unix"
"gotest.tools/v3/assert"
)
var (
testBuf = []byte("Buffalo1 buffalo2 Buffalo3 buffalo4 buffalo5 buffalo6 Buffalo7 buffalo8")
testBufSize = len(te... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/cmd/docker-proxy/udp_proxy_linux.go | cmd/docker-proxy/udp_proxy_linux.go | package main
import (
"encoding/binary"
"errors"
"log"
"net"
"os"
"sync"
"syscall"
"time"
"golang.org/x/net/ipv4"
"golang.org/x/net/ipv6"
)
const (
// DefaultConnTrackTimeout is the default timeout used for UDP connection
// tracking.
DefaultConnTrackTimeout = 90 * time.Second
// UDPBufSize is the buff... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/cmd/dockerd/main_windows.go | cmd/dockerd/main_windows.go | //go:generate go-winres make --arch=386,amd64,arm,arm64 --in=./winresources/winres.json --out=./resource
package main
import _ "github.com/moby/moby/v2/cmd/dockerd/winresources"
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/cmd/dockerd/main.go | cmd/dockerd/main.go | package main
import (
"context"
"fmt"
"os"
"os/signal"
"syscall"
"github.com/moby/sys/reexec"
"github.com/moby/term"
"github.com/moby/moby/v2/daemon/command"
)
func main() {
if reexec.Init() {
return
}
ctx := context.Background()
// Ignore SIGPIPE events. These are generated by systemd when journald ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/cmd/dockerd/winresources/winresources.go | cmd/dockerd/winresources/winresources.go | // Package winresources is used to embed Windows resources into dockerd.exe.
//
// These resources are used to provide:
// * Version information
// * An icon
// * A Windows manifest declaring Windows version support
// * Events message table
//
// The resource object files are generated when building with go-winres
// ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/doc.go | integration/doc.go | // Package integration provides integrations tests for Moby (API).
// These tests require a daemon (dockerd for now) to run.
package integration
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/system/cgroupdriver_systemd_test.go | integration/system/cgroupdriver_systemd_test.go | package system
import (
"os"
"testing"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/daemon"
"gotest.tools/v3/assert"
"gotest.tools/v3/skip"
)
// hasSystemd checks whether the host ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/system/api_test.go | integration/system/api_test.go | package system
import (
"net/http"
"testing"
"github.com/moby/moby/api/types/common"
"github.com/moby/moby/v2/internal/testutil/request"
"gotest.tools/v3/assert"
)
func TestAPIErrorNotFoundJSON(t *testing.T) {
ctx := setupTest(t)
// 404 is a different code path to normal errors, so test separately
httpResp,... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/system/login_test.go | integration/system/login_test.go | package system
import (
"fmt"
"testing"
"github.com/moby/moby/client"
registrypkg "github.com/moby/moby/v2/daemon/pkg/registry"
"github.com/moby/moby/v2/integration/internal/requirement"
"gotest.tools/v3/assert"
is "gotest.tools/v3/assert/cmp"
"gotest.tools/v3/skip"
)
// Test case for GitHub 22244
func TestL... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/system/main_test.go | integration/system/main_test.go | package system
import (
"context"
"os"
"testing"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/environment"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/codes"
)
var (
testEnv *environment.Execution
baseContext context.Context
)
func TestMain(m *testing.... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/system/info_linux_test.go | integration/system/info_linux_test.go | //go:build !windows
package system
import (
"encoding/json"
"io"
"net/http"
"testing"
"github.com/moby/moby/v2/internal/testutil/request"
"gotest.tools/v3/assert"
is "gotest.tools/v3/assert/cmp"
)
func TestInfoBinaryCommits(t *testing.T) {
ctx := setupTest(t)
// API v1.48 and lower returned both the "curr... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/system/event_test.go | integration/system/event_test.go | package system
import (
"context"
"errors"
"io"
"net/http"
"testing"
"time"
"github.com/moby/moby/api/types/events"
"github.com/moby/moby/api/types/mount"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
"github.com/moby/moby/v2/internal/testutil/request"
"gotest.tool... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/system/version_test.go | integration/system/version_test.go | package system
import (
"fmt"
"strconv"
"strings"
"testing"
"github.com/moby/moby/api/types/system"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/internal/testutil/request"
"gotest.tools/v3/assert"
is "gotest.tools/v3/assert/cmp"
)
func TestVersion(t *testing.T) {
ctx := setupTest(t)
apiClient :=... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/system/ping_test.go | integration/system/ping_test.go | package system
import (
"net/http"
"os"
"path/filepath"
"runtime"
"testing"
"github.com/moby/moby/api/types/build"
"github.com/moby/moby/api/types/swarm"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/daemon"
"github.com/moby/moby/v2/int... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/system/info_test.go | integration/system/info_test.go | package system
import (
"fmt"
"sort"
"testing"
"github.com/moby/moby/api/types/registry"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/daemon"
"gotest.tools/v3/assert"
is "gotest.tools/v3/assert/cmp"
"gotest.tools/v3/skip"
)
func TestIn... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/system/disk_usage_test.go | integration/system/disk_usage_test.go | package system
import (
"net/netip"
"testing"
"github.com/google/go-cmp/cmp/cmpopts"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/daemon"
"gotest.tools/v3/assert"
is "gotest.tools/... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/capabilities/main_linux_test.go | integration/capabilities/main_linux_test.go | package capabilities
import (
"context"
"os"
"testing"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/environment"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/codes"
)
var (
testEnv *environment.Execution
baseContext context.Context
)
func TestMain(m *te... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/capabilities/capabilities_linux_test.go | integration/capabilities/capabilities_linux_test.go | package capabilities
import (
"bytes"
"io"
"strings"
"testing"
"github.com/moby/moby/api/pkg/stdcopy"
containertypes "github.com/moby/moby/api/types/container"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/service/inspect_test.go | integration/service/inspect_test.go | package service
import (
"net/netip"
"testing"
"time"
"github.com/google/go-cmp/cmp"
"github.com/google/go-cmp/cmp/cmpopts"
"github.com/moby/moby/api/types/container"
swarmtypes "github.com/moby/moby/api/types/swarm"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/swarm"
"gotest.... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/service/create_test.go | integration/service/create_test.go | package service
import (
"context"
"io"
"strings"
"testing"
"time"
cerrdefs "github.com/containerd/errdefs"
"github.com/docker/go-units"
"github.com/moby/moby/api/types/container"
swarmtypes "github.com/moby/moby/api/types/swarm"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/n... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/service/plugin_test.go | integration/service/plugin_test.go | package service
import (
"io"
"path"
"strings"
"testing"
swarmtypes "github.com/moby/moby/api/types/swarm"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/swarm"
"github.com/moby/moby/v2/internal/testutil/daemon"
"github.com/moby/moby/v2/internal/testutil/fixtures/plugin"
"github... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/service/network_linux_test.go | integration/service/network_linux_test.go | package service
import (
stdnet "net"
"net/netip"
"strings"
"testing"
"time"
"github.com/google/go-cmp/cmp/cmpopts"
"github.com/moby/moby/api/types/network"
swarmtypes "github.com/moby/moby/api/types/swarm"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/daemon/libnetwork/scope"
"github.com/moby/mob... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/service/update_test.go | integration/service/update_test.go | package service
import (
"context"
"testing"
"github.com/moby/moby/api/types/container"
swarmtypes "github.com/moby/moby/api/types/swarm"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/network"
"github.com/moby/moby/v2/integration/internal/swarm"
"github.com/moby/moby/v2/internal/... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/service/main_test.go | integration/service/main_test.go | package service
import (
"context"
"os"
"testing"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/environment"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/codes"
)
var (
testEnv *environment.Execution
baseContext context.Context
)
func TestMain(m *testing... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/service/list_test.go | integration/service/list_test.go | package service
import (
"fmt"
"testing"
swarmtypes "github.com/moby/moby/api/types/swarm"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/swarm"
"gotest.tools/v3/assert"
is "gotest.tools/v3/assert/cmp"
"gotest.tools/v3/poll"
"gotest.tools/v3/skip"
)
// TestServiceListWithStatuse... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/service/jobs_test.go | integration/service/jobs_test.go | package service
import (
"testing"
swarmtypes "github.com/moby/moby/api/types/swarm"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/swarm"
"gotest.tools/v3/assert"
"gotest.tools/v3/poll"
"gotest.tools/v3/skip"
)
// The file jobs_test.go contains tests that verify that services whi... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/pkg_test.go | integration/plugin/pkg_test.go | package plugin
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/logging/read_test.go | integration/plugin/logging/read_test.go | package logging
import (
"bytes"
"runtime"
"strings"
"testing"
"time"
"github.com/moby/moby/api/pkg/stdcopy"
"github.com/moby/moby/api/types/container"
"github.com/moby/moby/client"
testContainer "github.com/moby/moby/v2/integration/internal/container"
"github.com/moby/moby/v2/internal/testutil"
"github.co... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/logging/logging_linux_test.go | integration/plugin/logging/logging_linux_test.go | package logging
import (
"bufio"
"context"
"os"
"strings"
"testing"
"time"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/daemon"
"gotest.tools/v3/assert"
"gotest.tools/v3/skip"
)... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/logging/helpers_test.go | integration/plugin/logging/helpers_test.go | package logging
import (
"context"
"os"
"os/exec"
"path/filepath"
"testing"
"github.com/moby/locker"
plugintypes "github.com/moby/moby/api/types/plugin"
"github.com/moby/moby/v2/internal/testutil/fixtures/plugin"
"github.com/pkg/errors"
"gotest.tools/v3/assert"
)
var pluginBuildLock = locker.New()
func en... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/logging/main_test.go | integration/plugin/logging/main_test.go | package logging
import (
"context"
"os"
"testing"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/environment"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/codes"
)
var (
testEnv *environment.Execution
baseContext context.Context
)
func TestMain(m *testing... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/logging/validation_test.go | integration/plugin/logging/validation_test.go | //go:build !windows
package logging
import (
"testing"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/daemon"
"gotest.tools/v3/assert"
"gotest.tools/v3/skip"
)
// Regression test for #35553
// Ensure that a daemon with a log plugin set as t... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/logging/cmd/discard/driver.go | integration/plugin/logging/cmd/discard/driver.go | package main
import (
"encoding/json"
"io"
"net/http"
"os"
"sync"
"syscall"
)
type startLoggingRequest struct {
File string
}
type capabilitiesResponse struct {
Cap struct {
ReadLogs bool
}
}
type driver struct {
mu sync.Mutex
logs map[string]io.Closer
}
type stopLoggingRequest struct {
File string... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/logging/cmd/discard/main_test.go | integration/plugin/logging/cmd/discard/main_test.go | package main
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/logging/cmd/discard/main.go | integration/plugin/logging/cmd/discard/main.go | package main
import (
"net"
"net/http"
"time"
)
func main() {
l, err := net.Listen("unix", "/run/docker/plugins/plugin.sock")
if err != nil {
panic(err)
}
mux := http.NewServeMux()
handle(mux)
server := http.Server{
Addr: l.Addr().String(),
Handler: mux,
ReadHeaderTimeout: 2 ... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/logging/cmd/close_on_start/main.go | integration/plugin/logging/cmd/close_on_start/main.go | package main
import (
"encoding/json"
"fmt"
"net"
"net/http"
"os"
"time"
)
type start struct {
File string
}
func main() {
l, err := net.Listen("unix", "/run/docker/plugins/plugin.sock")
if err != nil {
panic(err)
}
mux := http.NewServeMux()
mux.HandleFunc("/LogDriver.StartLogging", func(w http.Respon... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/logging/cmd/dummy/main.go | integration/plugin/logging/cmd/dummy/main.go | package main
import (
"net"
"net/http"
"time"
)
func main() {
l, err := net.Listen("unix", "/run/docker/plugins/plugin.sock")
if err != nil {
panic(err)
}
server := http.Server{
Addr: l.Addr().String(),
Handler: http.NewServeMux(),
ReadHeaderTimeout: 2 * time.Second, // This ser... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/authz/authz_plugin_v2_test.go | integration/plugin/authz/authz_plugin_v2_test.go | //go:build !windows
package authz
import (
"context"
"fmt"
"io"
"testing"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
"github.com/moby/moby/v2/integration/internal/requirement"
"gotest.tools/v3/assert"
"gotest.tools/v3/skip"
)
var (
authzPluginName = "... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/authz/main_windows_test.go | integration/plugin/authz/main_windows_test.go | package authz
| go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/authz/main_test.go | integration/plugin/authz/main_test.go | //go:build !windows
package authz
import (
"context"
"encoding/json"
"fmt"
"io"
"net/http"
"net/http/httptest"
"os"
"strings"
"testing"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/daemon"
"github.com/moby/moby/v2/internal/testutil/environment"
"github.com/moby/... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/authz/authz_plugin_test.go | integration/plugin/authz/authz_plugin_test.go | //go:build !windows
package authz
import (
"context"
"errors"
"fmt"
"io"
"net"
"net/http"
"net/url"
"os"
"path/filepath"
"strconv"
"strings"
"testing"
"time"
"github.com/docker/go-connections/sockets"
"github.com/moby/go-archive"
eventtypes "github.com/moby/moby/api/types/events"
"github.com/moby/mo... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/volumes/mounts_test.go | integration/plugin/volumes/mounts_test.go | package volumes
import (
"os"
"testing"
plugintypes "github.com/moby/moby/api/types/plugin"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/daemon"
"github.com/moby/moby/v2/internal/testutil/fixtures/plugin"
"gotest.tools/v3/assert"
"gotest... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/volumes/helpers_test.go | integration/plugin/volumes/helpers_test.go | package volumes
import (
"context"
"os"
"os/exec"
"path/filepath"
"testing"
"time"
"github.com/moby/locker"
plugintypes "github.com/moby/moby/api/types/plugin"
"github.com/moby/moby/v2/internal/testutil/fixtures/plugin"
"github.com/pkg/errors"
"gotest.tools/v3/assert"
)
var pluginBuildLock = locker.New()
... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/volumes/main_test.go | integration/plugin/volumes/main_test.go | package volumes
import (
"context"
"os"
"testing"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/environment"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/codes"
)
var (
testEnv *environment.Execution
baseContext context.Context
)
func TestMain(m *testing... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/volumes/cmd/dummy/main.go | integration/plugin/volumes/cmd/dummy/main.go | package main
import (
"net"
"net/http"
"time"
)
func main() {
l, err := net.Listen("unix", "/run/docker/plugins/plugin.sock")
if err != nil {
panic(err)
}
server := http.Server{
Addr: l.Addr().String(),
Handler: http.NewServeMux(),
ReadHeaderTimeout: 2 * time.Second, // This ser... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/common/plugin_test.go | integration/plugin/common/plugin_test.go | package common
import (
"encoding/base64"
"encoding/json"
"fmt"
"io"
"net"
"net/http"
"os"
"path"
"path/filepath"
"strings"
"testing"
c8dimages "github.com/containerd/containerd/v2/core/images"
"github.com/containerd/containerd/v2/core/remotes/docker"
"github.com/moby/moby/api/types/jsonstream"
registr... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/plugin/common/main_test.go | integration/plugin/common/main_test.go | package common
import (
"context"
"os"
"testing"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/environment"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/attribute"
"go.opentelemetry.io/otel/codes"
)
var (
testEnv *environment.Execution
baseContext contex... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/history_test.go | integration/image/history_test.go | package image
import (
"context"
"io"
"testing"
buildtypes "github.com/moby/moby/api/types/build"
"github.com/moby/moby/client"
build "github.com/moby/moby/v2/integration/internal/build"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/fakecontext"
ocispec "github.com/op... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/inspect_test.go | integration/image/inspect_test.go | package image
import (
"bytes"
"encoding/json"
"testing"
"github.com/moby/moby/client"
iimage "github.com/moby/moby/v2/integration/internal/image"
"github.com/moby/moby/v2/internal/testutil/specialimage"
ocispec "github.com/opencontainers/image-spec/specs-go/v1"
"gotest.tools/v3/assert"
is "gotest.tools/v3/a... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/tag_test.go | integration/image/tag_test.go | package image
import (
"fmt"
"testing"
"github.com/moby/moby/client"
"gotest.tools/v3/assert"
is "gotest.tools/v3/assert/cmp"
)
// tagging a named image in a new unprefixed repo should work
func TestTagUnprefixedRepoByNameOrName(t *testing.T) {
ctx := setupTest(t)
apiClient := testEnv.APIClient()
// By nam... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/commit_test.go | integration/image/commit_test.go | package image
import (
"context"
"strings"
"testing"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
"github.com/moby/moby/v2/internal/testutil/daemon"
"gotest.tools/v3/assert"
is "gotest.tools/v3/assert/cmp"
"gotest.tools/v3/poll"
"gotest.tools/v3/skip"
)
func TestCo... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/pull_test.go | integration/image/pull_test.go | package image
import (
"bytes"
"context"
"encoding/json"
"fmt"
"io"
"os"
"path"
"strings"
"testing"
containerd "github.com/containerd/containerd/v2/client"
"github.com/containerd/containerd/v2/core/content"
c8dimages "github.com/containerd/containerd/v2/core/images"
"github.com/containerd/containerd/v2/p... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/main_test.go | integration/image/main_test.go | package image
import (
"context"
"os"
"testing"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/environment"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/codes"
)
var (
testEnv *environment.Execution
baseContext context.Context
)
func TestMain(m *testing.M... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/remove_test.go | integration/image/remove_test.go | package image
import (
"strings"
"testing"
cerrdefs "github.com/containerd/errdefs"
"github.com/containerd/platforms"
"github.com/moby/moby/api/types/image"
"github.com/moby/moby/client"
"github.com/moby/moby/client/pkg/stringid"
build "github.com/moby/moby/v2/integration/internal/build"
"github.com/moby/mo... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/list_test.go | integration/image/list_test.go | package image
import (
"fmt"
"slices"
"strings"
"testing"
"time"
"github.com/google/go-cmp/cmp/cmpopts"
"github.com/moby/moby/api/types/image"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
iimage "github.com/moby/moby/v2/integration/internal/image"
"github.com/moby/... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/save_test.go | integration/image/save_test.go | package image
import (
"archive/tar"
"encoding/json"
"io"
"io/fs"
"os"
"path/filepath"
"reflect"
"sort"
"strings"
"testing"
"time"
"github.com/cpuguy83/tar2go"
"github.com/moby/go-archive/compression"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/build"
"github.com/moby/m... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/load_test.go | integration/image/load_test.go | package image
import (
"slices"
"testing"
cerrdefs "github.com/containerd/errdefs"
"github.com/moby/moby/api/types/image"
"github.com/moby/moby/client"
iimage "github.com/moby/moby/v2/integration/internal/image"
"github.com/moby/moby/v2/internal/testutil/specialimage"
ocispec "github.com/opencontainers/image-... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/size_test.go | integration/image/size_test.go | package image
import (
"testing"
"github.com/moby/moby/client"
"gotest.tools/v3/assert"
)
// Test case for 30027: image size reported as -1
// in v1.12 client against v1.13 daemon.
func TestImagesSizeCompatibility(t *testing.T) {
ctx := setupTest(t)
testCases := []struct {
name string
apiVersion stri... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/prune_test.go | integration/image/prune_test.go | package image
import (
"strings"
"testing"
"github.com/moby/moby/api/types/image"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
iimage "github.com/moby/moby/v2/integration/internal/image"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/tes... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/image/import_test.go | integration/image/import_test.go | package image
import (
"archive/tar"
"bytes"
"io"
"net/http/httptest"
"runtime"
"strconv"
"strings"
"testing"
cerrdefs "github.com/containerd/errdefs"
"github.com/containerd/platforms"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/dae... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/container/wait_test.go | integration/container/wait_test.go | package container
import (
"testing"
"time"
containertypes "github.com/moby/moby/api/types/container"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/request"
"gotest.tools/v3/assert"
... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/container/devices_windows_test.go | integration/container/devices_windows_test.go | package container
import (
"strings"
"testing"
containertypes "github.com/moby/moby/api/types/container"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
"github.com/moby/moby/v2/internal/testutil"
"gotest.tools/v3/assert"
"gotest.tools/v3/skip"
)
// TestWindowsDevices t... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/container/daemon_test.go | integration/container/daemon_test.go | package container
import (
"testing"
"github.com/moby/moby/api/types/network"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
"github.com/moby/moby/v2/internal/testutil"
"github.com/moby/moby/v2/internal/testutil/daemon"
"gotest.tools/v3/assert"
is "gotest.tools/v3/asser... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/container/stop_test.go | integration/container/stop_test.go | package container
import (
"testing"
"time"
containertypes "github.com/moby/moby/api/types/container"
"github.com/moby/moby/client"
"github.com/moby/moby/v2/integration/internal/container"
"gotest.tools/v3/assert"
is "gotest.tools/v3/assert/cmp"
"gotest.tools/v3/poll"
"gotest.tools/v3/skip"
)
// hcs can som... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
moby/moby | https://github.com/moby/moby/blob/015cd3d3fdf4a1ad9f27f132013bea7838da721b/integration/container/attach_test.go | integration/container/attach_test.go | package container
import (
"testing"
"time"
"github.com/moby/moby/api/types"
"github.com/moby/moby/api/types/container"
"github.com/moby/moby/api/types/network"
"github.com/moby/moby/client"
systemutil "github.com/moby/moby/v2/integration/internal/system"
"github.com/moby/moby/v2/internal/testutil"
"github.c... | go | Apache-2.0 | 015cd3d3fdf4a1ad9f27f132013bea7838da721b | 2026-01-07T08:35:43.425641Z | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.