mirror of
https://github.com/kopia/kopia.git
synced 2026-05-24 14:44:47 -04:00
Remove FIO_USE_DOCKER env
This commit is contained in:
2
Makefile
2
Makefile
@@ -163,9 +163,7 @@ integration-tests: dist-binary
|
||||
KOPIA_EXE=$(KOPIA_INTEGRATION_EXE) $(GO_TEST) $(TEST_FLAGS) -count=1 -parallel $(PARALLEL) -timeout 600s github.com/kopia/kopia/tests/end_to_end_test
|
||||
|
||||
robustness-tool-tests:
|
||||
FIO_EXE="$(shell which fio)" \
|
||||
FIO_DOCKER_IMAGE=$(FIO_DOCKER_TAG) \
|
||||
FIO_USE_DOCKER=1 \
|
||||
$(GO_TEST) $(TEST_FLAGS) -count=1 -timeout 90s github.com/kopia/kopia/tests/tools/...
|
||||
|
||||
stress-test:
|
||||
|
||||
@@ -36,9 +36,7 @@
|
||||
|
||||
// FioDockerImageEnvKey specifies the docker image tag to use. If
|
||||
// FioExeEnvKey is set, the local executable will be used instead of
|
||||
// docker, even if this variable is also set. The exception is if
|
||||
// FioUseDockerEnvKey is not an empty string, which will force
|
||||
// use of the fio docker image independent of FioExeEnvKey.
|
||||
// docker, even if this variable is also set.
|
||||
FioDockerImageEnvKey = "FIO_DOCKER_IMAGE"
|
||||
|
||||
// LocalFioDataPathEnvKey is the local path where fio data will be
|
||||
@@ -49,10 +47,6 @@
|
||||
// relative to the docker host. If left blank, defaults to local fio data path
|
||||
// (works unless running via docker from within a container, e.g. for development)
|
||||
HostFioDataPathEnvKey = "HOST_FIO_DATA_PATH"
|
||||
|
||||
// FioUseDockerEnvKey forces the fio runner to use the docker image, even if
|
||||
// an executable path is provided.
|
||||
FioUseDockerEnvKey = "FIO_USE_DOCKER"
|
||||
)
|
||||
|
||||
// Known error messages
|
||||
@@ -75,7 +69,6 @@ func NewRunner() (fr *Runner, err error) {
|
||||
imgStr := os.Getenv(FioDockerImageEnvKey)
|
||||
localFioDataPathStr := os.Getenv(LocalFioDataPathEnvKey)
|
||||
hostFioDataPathStr := os.Getenv(HostFioDataPathEnvKey)
|
||||
forceDocker := os.Getenv(FioUseDockerEnvKey) != ""
|
||||
|
||||
var exeArgs []string
|
||||
|
||||
@@ -89,7 +82,7 @@ func NewRunner() (fr *Runner, err error) {
|
||||
}
|
||||
|
||||
switch {
|
||||
case exeStr != "" && !forceDocker:
|
||||
case exeStr != "":
|
||||
// Provided a local FIO executable to run
|
||||
Exe = exeStr
|
||||
|
||||
@@ -171,13 +164,13 @@ func (fr *Runner) verifySetupWithTestWrites() error {
|
||||
|
||||
opt := Options{}.WithNumFiles(nrFiles).WithFileSize(fileSizeB)
|
||||
|
||||
defer fr.DeleteRelDir("test") //nolint:errcheck
|
||||
|
||||
err := fr.WriteFiles(subDirPath, opt)
|
||||
if err != nil {
|
||||
return errors.Wrap(err, "unable to perform writes")
|
||||
}
|
||||
|
||||
defer fr.DeleteRelDir("test") //nolint:errcheck
|
||||
|
||||
fl, err := ioutil.ReadDir(filepath.Join(fr.LocalDataDir, subDirPath))
|
||||
if err != nil {
|
||||
return errors.Wrapf(err, "error reading path %v", subDirPath)
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package fio
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"os"
|
||||
"path/filepath"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user