Fix: Use conditional container base for E2E compatibility
- Alpine for OSS tests (better old arch dashboardScene=false compatibility) - Ubuntu for Enterprise tests (when image renderer needed) - Restores original release-12.0.3 Alpine behavior for OSS - Should resolve old arch E2E test failures
This commit is contained in:
@@ -74,9 +74,17 @@ func GrafanaService(ctx context.Context, d *dagger.Client, opts GrafanaServiceOp
|
||||
WithExec([]string{"yarn", "install", "--immutable"}).
|
||||
WithExec([]string{"yarn", "e2e:plugin:build"})
|
||||
|
||||
// _/ubuntu:latest sticks to latest LTS.
|
||||
// We need ubuntu to support the image renderer plugin, which assumes glibc.
|
||||
container := d.Container().From("ubuntu:latest").
|
||||
// Conditional container base: Alpine for OSS (better old arch compatibility), Ubuntu for Enterprise (image renderer support)
|
||||
var container *dagger.Container
|
||||
if opts.InstallImageRenderer {
|
||||
// Ubuntu needed for image renderer (Enterprise workflows)
|
||||
container = d.Container().From("ubuntu:latest")
|
||||
} else {
|
||||
// Alpine for OSS - better compatibility with original release-12.0.3 and old arch tests
|
||||
container = d.Container().From("alpine").WithExec([]string{"apk", "add", "bash"})
|
||||
}
|
||||
|
||||
container = container.
|
||||
WithMountedFile("/src/grafana.tar.gz", opts.GrafanaTarGz).
|
||||
WithExec([]string{"mkdir", "-p", "/src/grafana"}).
|
||||
WithExec([]string{"tar", "--strip-components=1", "-xzf", "/src/grafana.tar.gz", "-C", "/src/grafana"}).
|
||||
|
||||
Reference in New Issue
Block a user