Files
linuxkit/vendor/github.com/docker/infrakit/pkg/template/defaults.go
Rolf Neugebauer 48845bcfd9 infrakit: Move the hyperkit instance plugin into the source directory
- The tools directory ideally should not contain source code
- Removes double vendoring of packagages
- Makes it easer to hook the build into the top-level Makefile

Eventually, the plugin should be moved to the infrakit repo.

Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
2017-03-25 13:02:45 +01:00

17 lines
283 B
Go

package template
import (
"os"
)
// defaultContextURL returns the default context URL if none is known.
func defaultContextURL() string {
pwd := "/"
if wd, err := os.Getwd(); err == nil {
pwd = wd
} else {
pwd = os.Getenv("PWD")
}
return "file://localhost" + pwd + "/"
}