fix #108 - ensure container names are unique for matrix runs

This commit is contained in:
Casey Lee 2020-03-04 16:24:14 -08:00
parent 4f84be12e3
commit 59b9b8e97a
No known key found for this signature in database
GPG key ID: 1899120ECD0A1784
3 changed files with 12 additions and 2 deletions

2
.actrc
View file

@ -1 +1 @@
-P ubuntu-latest=nektos/act-environments-ubuntu:18.04
-P ubuntu-latest=nektos/act-environments-ubuntu:18.04

View file

@ -63,7 +63,7 @@ func (runner *runnerImpl) NewPlanExecutor(plan *model.Plan) common.Executor {
for i, matrix := range matrixes {
rc := runner.newRunContext(run, matrix)
if len(matrix) > 1 {
if len(matrixes) > 1 {
rc.Name = fmt.Sprintf("%s-%d", rc.Name, i+1)
}
if len(rc.String()) > maxJobNameLen {

View file

@ -13,3 +13,13 @@ jobs:
matrix:
os: [ubuntu-18.04, macos-latest]
node: [4, 6, 8, 10]
test:
runs-on: ubuntu-latest
strategy:
matrix:
node: [8.x, 10.x, 12.x, 13.x]
steps:
- run: echo ${NODE_VERSION} | grep ${{ matrix.node }}
env:
NODE_VERSION: ${{ matrix.node }}