• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

kubernetes / kompose / 6696194161

30 Oct 2023 05:02PM UTC coverage: 54.96%. Remained the same
6696194161

push

github

web-flow
chore(deps)(deps): bump golang.org/x/tools from 0.13.0 to 0.14.0 (#1723)

Bumps [golang.org/x/tools](https://github.com/golang/tools) from 0.13.0 to 0.14.0.
- [Release notes](https://github.com/golang/tools/releases)
- [Commits](https://github.com/golang/tools/compare/v0.13.0...v0.14.0)

---
updated-dependencies:
- dependency-name: golang.org/x/tools
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

2205 of 4012 relevant lines covered (54.96%)

7.91 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/pkg/utils/docker/client.go
1
/*
2
Copyright 2016 The Kubernetes Authors All rights reserved
3

4
Licensed under the Apache License, Version 2.0 (the "License");
5
you may not use this file except in compliance with the License.
6
You may obtain a copy of the License at
7

8
    http://www.apache.org/licenses/LICENSE-2.0
9

10
Unless required by applicable law or agreed to in writing, software
11
distributed under the License is distributed on an "AS IS" BASIS,
12
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
See the License for the specific language governing permissions and
14
limitations under the License.
15
*/
16

17
package docker
18

19
import (
20
        "os"
21

22
        docker "github.com/fsouza/go-dockerclient"
23
)
24

25
// Client connects to Docker client on host
26
func Client() (*docker.Client, error) {
×
27
        var (
×
28
                err    error
×
29
                client *docker.Client
×
30
        )
×
31

×
32
        dockerHost := os.Getenv("DOCKER_HOST")
×
33

×
34
        if len(dockerHost) > 0 {
×
35
                // Create client instance from Docker's environment variables:
×
36
                // DOCKER_HOST, DOCKER_TLS_VERIFY, DOCKER_CERT_PATH
×
37
                client, err = docker.NewClientFromEnv()
×
38
        } else {
×
39
                // Default unix socket end-point
×
40
                endpoint := "unix:///var/run/docker.sock"
×
41
                client, err = docker.NewClient(endpoint)
×
42
        }
×
43
        if err != nil {
×
44
                return client, err
×
45
        }
×
46

47
        return client, nil
×
48
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc