e2e tests in CI

Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
This commit is contained in:
Nicolas De Loof 2025-06-26 15:07:01 +02:00 committed by Nicolas De loof
parent a9e76943f6
commit 26e46d7cc8
3 changed files with 21 additions and 6 deletions

View File

@ -183,6 +183,12 @@ jobs:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Set up Docker Model
run: |
sudo apt-get install docker-model-plugin
docker model version
docker info
- name: Set up Go
uses: actions/setup-go@v5
with:

View File

@ -224,13 +224,23 @@ func findPluginExecutable(pluginExecutableName string) (string, error) {
if err != nil {
return "", err
}
bin, err := filepath.Abs(filepath.Join(userDir, dockerUserDir, pluginExecutableName))
if err != nil {
return "", err
candidates := []string{
filepath.Join(userDir, dockerUserDir),
"/usr/local/lib/docker/cli-plugins",
"/usr/local/libexec/docker/cli-plugins",
"/usr/lib/docker/cli-plugins",
"/usr/libexec/docker/cli-plugins",
}
if _, err := os.Stat(bin); err == nil {
return bin, nil
for _, path := range candidates {
bin, err := filepath.Abs(filepath.Join(path, pluginExecutableName))
if err != nil {
return "", err
}
if _, err := os.Stat(bin); err == nil {
return bin, nil
}
}
return "", fmt.Errorf("plugin not found %s: %w", pluginExecutableName, os.ErrNotExist)
}

View File

@ -21,7 +21,6 @@ import (
)
func TestComposeModel(t *testing.T) {
t.Skip("require model-cli on GHA runners")
c := NewParallelCLI(t)
defer c.cleanupWithDown(t, "model-test")