Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Go modules had pulled down the latest semvar tag, which was actually super old, had to specify the commit hash of github.com/moby/moby to get the actual up-to-date module. Fixed ipfs package dependencies as they are now go module compatible and so indirect deps don't need to be listed in this packages go.mod file. Fixed tests so that they didn't attempt to pull a private image, as well as not running TestRemoveAllImages by default, as it does as it says... Fixed util to take the official docker images into account, as their url is docker.io/library/<container> but the container name is just <container>, instead of library/<container>.
- Loading branch information
Showing
552 changed files
with
60,143 additions
and
14,340 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,21 @@ | ||
package docker | ||
|
||
import "regexp" | ||
import ( | ||
"regexp" | ||
"strings" | ||
) | ||
|
||
// ShortImageID returns the short version of an image ID | ||
func ShortImageID(imageID string) string { | ||
re := regexp.MustCompile(`(sha256:)?([0-9a-zA-Z]{12}).*`) | ||
return re.ReplaceAllString(imageID, `$2`) | ||
} | ||
|
||
// TestStripImageTagHost strips the host from an image tag | ||
// StripImageTagHost strips the host from an image tag | ||
func StripImageTagHost(imageTag string) string { | ||
re := regexp.MustCompile(`(.*\..*?\/)?(.*)`) | ||
matches := re.FindStringSubmatch(imageTag) | ||
imageTag = matches[len(matches)-1] | ||
imageTag = strings.TrimPrefix(imageTag, "library/") | ||
return imageTag | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,42 +1,30 @@ | ||
module github.com/miguelmota/ipdr | ||
|
||
go 1.12 | ||
|
||
require ( | ||
github.com/Microsoft/go-winio v0.4.11 // indirect | ||
github.com/btcsuite/btcd v0.0.0-20190213025234-306aecffea32 // indirect | ||
github.com/cheekybits/is v0.0.0-20150225183255-68e9c0620927 // indirect | ||
github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78 // indirect | ||
github.com/Microsoft/go-winio v0.4.12 // indirect | ||
github.com/docker/distribution v2.7.1+incompatible // indirect | ||
github.com/docker/docker v1.13.1 | ||
github.com/docker/docker v0.7.3-0.20190307005417-54dddadc7d5d | ||
github.com/docker/go-connections v0.4.0 // indirect | ||
github.com/docker/go-units v0.3.3 // indirect | ||
github.com/fatih/color v1.7.0 | ||
github.com/gogo/protobuf v1.2.0 // indirect | ||
github.com/gxed/hashland v0.0.0-20180221191214-d9f6b97f8db2 // indirect | ||
github.com/google/go-cmp v0.2.0 // indirect | ||
github.com/gorilla/mux v1.7.0 // indirect | ||
github.com/inconshreveable/mousetrap v1.0.0 // indirect | ||
github.com/ipfs/go-ipfs-api v1.3.5 | ||
github.com/ipfs/go-ipfs-cmdkit v1.1.3 // indirect | ||
github.com/ipfs/go-ipfs-api v0.0.1 | ||
github.com/jbenet/go-base58 v0.0.0-20150317085156-6237cf65f3a6 | ||
github.com/libp2p/go-flow-metrics v0.2.0 // indirect | ||
github.com/libp2p/go-libp2p-crypto v2.0.5+incompatible // indirect | ||
github.com/libp2p/go-libp2p-metrics v2.1.7+incompatible // indirect | ||
github.com/libp2p/go-libp2p-peer v2.4.0+incompatible // indirect | ||
github.com/libp2p/go-libp2p-protocol v1.0.0 // indirect | ||
github.com/libp2p/go-libp2p-pubsub v0.11.10 // indirect | ||
github.com/mattn/go-colorable v0.1.0 // indirect | ||
github.com/mattn/go-isatty v0.0.4 // indirect | ||
github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1 // indirect | ||
github.com/minio/sha256-simd v0.0.0-20190131020904-2d45a736cd16 // indirect | ||
github.com/mitchellh/go-homedir v1.1.0 // indirect | ||
github.com/mr-tron/base58 v1.1.0 // indirect | ||
github.com/multiformats/go-multiaddr v1.4.0 // indirect | ||
github.com/multiformats/go-multiaddr-dns v0.2.5 // indirect | ||
github.com/multiformats/go-multiaddr-net v1.7.1 // indirect | ||
github.com/multiformats/go-multihash v1.0.8 // indirect | ||
github.com/mattn/go-colorable v0.1.1 // indirect | ||
github.com/mattn/go-isatty v0.0.6 // indirect | ||
github.com/morikuni/aec v0.0.0-20170113033406-39771216ff4c // indirect | ||
github.com/opencontainers/go-digest v1.0.0-rc1 // indirect | ||
github.com/opencontainers/image-spec v1.0.1 // indirect | ||
github.com/pkg/errors v0.8.1 // indirect | ||
github.com/sirupsen/logrus v1.3.0 | ||
github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72 // indirect | ||
github.com/spf13/cobra v0.0.3 | ||
github.com/spf13/pflag v1.0.3 // indirect | ||
github.com/whyrusleeping/tar-utils v0.0.0-20180509141711-8c6c8ba81d5c // indirect | ||
golang.org/x/net v0.0.0-20190213061140-3a22650c66bd // indirect | ||
golang.org/x/time v0.0.0-20181108054448-85acf8d2951c // indirect | ||
google.golang.org/grpc v1.19.0 // indirect | ||
gotest.tools v2.2.0+incompatible // indirect | ||
) |
Oops, something went wrong.