support runner.arch (#1290)
* support runner.arch Signed-off-by: Fabian Kammel <fk@edgeless.systems> * add arch to runner definition Signed-off-by: Fabian Kammel <fk@edgeless.systems> * get architecture from docker Signed-off-by: Fabian Kammel <fk@edgeless.systems> * Update pkg/container/docker_run.go Co-authored-by: ChristopherHX <christopher.homberger@web.de> * lint: goimport file Signed-off-by: Fabian Kammel <fk@edgeless.systems> Co-authored-by: Casey Lee <caseypl@amazon.com> Co-authored-by: ChristopherHX <christopher.homberger@web.de> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
This commit is contained in:
@@ -7,6 +7,7 @@ import (
|
||||
"strings"
|
||||
|
||||
"github.com/nektos/act/pkg/common"
|
||||
"github.com/nektos/act/pkg/container"
|
||||
"github.com/nektos/act/pkg/exprparser"
|
||||
"gopkg.in/yaml.v3"
|
||||
)
|
||||
@@ -47,6 +48,7 @@ func (rc *RunContext) NewExpressionEvaluator(ctx context.Context) ExpressionEval
|
||||
Steps: rc.getStepsContext(),
|
||||
Runner: map[string]interface{}{
|
||||
"os": "Linux",
|
||||
"arch": container.RunnerArch(ctx),
|
||||
"temp": "/tmp",
|
||||
"tool_cache": "/opt/hostedtoolcache",
|
||||
},
|
||||
@@ -92,6 +94,7 @@ func (rc *RunContext) NewStepExpressionEvaluator(ctx context.Context, step step)
|
||||
Steps: rc.getStepsContext(),
|
||||
Runner: map[string]interface{}{
|
||||
"os": "Linux",
|
||||
"arch": container.RunnerArch(ctx),
|
||||
"temp": "/tmp",
|
||||
"tool_cache": "/opt/hostedtoolcache",
|
||||
},
|
||||
|
Reference in New Issue
Block a user