[GH-ISSUE #747] Issue: Unable to set GitHub environment variable #469

Closed
opened 2026-03-01 21:43:42 +03:00 by kerem · 4 comments
Owner

Originally created by @SeanWrightSec on GitHub (Jul 1, 2021).
Original GitHub issue: https://github.com/nektos/act/issues/747

System information

  • Operating System: macOS
  • Architecture: arm64
  • Apple M1: yes
  • Docker version: 20.10.7
  • Docker image used in act: catthehacker/ubuntu:act-latest
  • act version: 0.2.23

Expected behaviour

I've attempting to set an environment variable within an entrypoint script in an action:

echo 'RESULT<<EOF' >> $GITHUB_ENV
cat /etc/hosts >> $GITHUB_ENV
echo 'EOF' >> $GITHUB_ENV

Actual behaviour

When running this action I get the following error:

/entrypoint.sh: line 10: /var/run/act/workflow/envs.txt: No such file or directory

Workflow and/or repository

  1. Clone repo https://github.com/SeanWrightSec/bandit.git
  2. Enter cloned repo directory
  3. Run act

act output

Log
DEBU[0000] Loading environment from /tmp/bandit/.env    
DEBU[0000] Loading secrets from /tmp/bandit/.secrets    
DEBU[0000] Loading workflows from '/tmp/bandit/.github/workflows' 
DEBU[0000] Loading workflows recursively                
DEBU[0000] Found workflow 'main.yml' in '/tmp/bandit/.github/workflows/main.yml' 
DEBU[0000] Reading workflow '/tmp/bandit/.github/workflows/main.yml' 
DEBU[0000] Correcting if statements '/tmp/bandit/.github/workflows/main.yml' 
DEBU[0000] Planning event: push                         
DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' 
DEBU[0000] using github ref: refs/heads/main            
DEBU[0000] context env => map[ACT:true]                 
[bandit/Run bandit scan] 🚀  Start image=catthehacker/ubuntu:act-latest
DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' 
DEBU[0000] using github ref: refs/heads/main            
[bandit/Run bandit scan]   🐳  docker pull catthehacker/ubuntu:act-latest
DEBU[0000] Image exists? true                           
[bandit/Run bandit scan] Removed container: b6d8108d3ab5a7f66a0c9705fc06edb419df7338853b8fe568641d81b6f9a38e
[bandit/Run bandit scan]   🐳  docker volume rm act-bandit-Run-bandit-scan
[bandit/Run bandit scan]   🐳  docker create image=catthehacker/ubuntu:act-latest platform= entrypoint=["/usr/bin/tail" "-f" "/dev/null"] cmd=[]
[bandit/Run bandit scan] Created container name=act-bandit-Run-bandit-scan id=fa2f2a536271bea7ba5d01e7aa0599daf17202a3309d430c2f4182b5a815d8f9 from image catthehacker/ubuntu:act-latest (platform: )
[bandit/Run bandit scan] ENV ==> [RUNNER_TOOL_CACHE=/opt/hostedtoolcache RUNNER_OS=Linux RUNNER_TEMP=/tmp]
[bandit/Run bandit scan]   🐳  docker run image=catthehacker/ubuntu:act-latest platform= entrypoint=["/usr/bin/tail" "-f" "/dev/null"] cmd=[]
[bandit/Run bandit scan] Starting container: fa2f2a536271bea7ba5d01e7aa0599daf17202a3309d430c2f4182b5a815d8f9
[bandit/Run bandit scan] Started container: fa2f2a536271bea7ba5d01e7aa0599daf17202a3309d430c2f4182b5a815d8f9
[bandit/Run bandit scan]   🐳  docker exec cmd=[mkdir -m 0777 -p /var/run/act] user=root
[bandit/Run bandit scan] Exec command '[mkdir -m 0777 -p /var/run/act]'
[bandit/Run bandit scan]   🐳  docker cp src=/tmp/bandit/. dst=/tmp/bandit
[bandit/Run bandit scan]   🐳  docker exec cmd=[mkdir -p /tmp/bandit] user=
[bandit/Run bandit scan] Exec command '[mkdir -p /tmp/bandit]'
DEBU[0000] Writing tarball /var/folders/ty/trwr80zs6_g38vlmmkh3xrhm0000gn/T/act575372720 from /tmp/bandit/. 
DEBU[0000] Stripping prefix:/tmp/bandit/ src:/tmp/bandit/. 
[bandit/Run bandit scan] Extracting content from '/var/folders/ty/trwr80zs6_g38vlmmkh3xrhm0000gn/T/act575372720' to '/tmp/bandit'
DEBU[0000] Writing entry to tarball workflow/event.json len:2 
DEBU[0000] Writing entry to tarball workflow/envs.txt len:0 
DEBU[0000] Writing entry to tarball workflow/paths.txt len:0 
[bandit/Run bandit scan] Extracting content to '/var/run/act/'
DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' 
DEBU[0000] using github ref: refs/heads/main            
DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' 
DEBU[0000] using github ref: refs/heads/main            
DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] 
DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache CI:true DEPLOYMENT_BASEPATH:/opt/runner GITHUB_ACTION:0 GITHUB_ACTIONS:true GITHUB_ACTION_REF: GITHUB_ACTION_REPOSITORY: GITHUB_ACTOR:nektos/act GITHUB_API_URL:https://api.github.com GITHUB_BASE_REF: GITHUB_ENV:/var/run/act/workflow/envs.txt GITHUB_EVENT_NAME:push GITHUB_EVENT_PATH:/var/run/act/workflow/event.json GITHUB_GRAPHQL_URL:https://api.github.com/graphql GITHUB_HEAD_REF: GITHUB_JOB:Run bandit scan GITHUB_PATH:/var/run/act/workflow/paths.txt GITHUB_REF:refs/heads/main GITHUB_REPOSITORY:SeanWrightSec/bandit GITHUB_REPOSITORY_OWNER:SeanWrightSec GITHUB_RETENTION_DAYS:0 GITHUB_RUN_ID:1 GITHUB_RUN_NUMBER:1 GITHUB_SERVER_URL:https://github.com GITHUB_SHA:2fb7067c7e6be976cc4b5f5f58092cc5b962508c GITHUB_TOKEN: GITHUB_WORKFLOW:bandit GITHUB_WORKSPACE:/tmp/bandit IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_PERFLOG:/dev/null RUNNER_TRACKING_ID: RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] 
[bandit/Run bandit scan] setupEnv => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache CI:true DEPLOYMENT_BASEPATH:/opt/runner GITHUB_ACTION:0 GITHUB_ACTIONS:true GITHUB_ACTION_REF: GITHUB_ACTION_REPOSITORY: GITHUB_ACTOR:nektos/act GITHUB_API_URL:https://api.github.com GITHUB_BASE_REF: GITHUB_ENV:/var/run/act/workflow/envs.txt GITHUB_EVENT_NAME:push GITHUB_EVENT_PATH:/var/run/act/workflow/event.json GITHUB_GRAPHQL_URL:https://api.github.com/graphql GITHUB_HEAD_REF: GITHUB_JOB:Run bandit scan GITHUB_PATH:/var/run/act/workflow/paths.txt GITHUB_REF:refs/heads/main GITHUB_REPOSITORY:SeanWrightSec/bandit GITHUB_REPOSITORY_OWNER:SeanWrightSec GITHUB_RETENTION_DAYS:0 GITHUB_RUN_ID:1 GITHUB_RUN_NUMBER:1 GITHUB_SERVER_URL:https://github.com GITHUB_SHA:2fb7067c7e6be976cc4b5f5f58092cc5b962508c GITHUB_TOKEN: GITHUB_WORKFLOW:bandit GITHUB_WORKSPACE:/tmp/bandit IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_PERFLOG:/dev/null RUNNER_TRACKING_ID: RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root]
[bandit/Run bandit scan] ⭐  Run Checkout
DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' 
DEBU[0000] using github ref: refs/heads/main            
[bandit/Run bandit scan] Skipping local actions/checkout because workdir was already copied
[bandit/Run bandit scan]   ✅  Success - Checkout
DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' 
DEBU[0000] using github ref: refs/heads/main            
DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' 
DEBU[0000] using github ref: refs/heads/main            
DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] 
DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' 
DEBU[0000] using github ref: refs/heads/main            
DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] 
DEBU[0000] Evaluating 'github['event']['repository']['name']' instead of 'github.event.repository.name' 
DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' 
DEBU[0000] using github ref: refs/heads/main            
DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] 
DEBU[0000] Evaluating 'github['workspace']' instead of 'github.workspace' 
DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache CI:true DEPLOYMENT_BASEPATH:/opt/runner GITHUB_ACTION:bandit GITHUB_ACTIONS:true GITHUB_ACTION_REF: GITHUB_ACTION_REPOSITORY: GITHUB_ACTOR:nektos/act GITHUB_API_URL:https://api.github.com GITHUB_BASE_REF: GITHUB_ENV:/var/run/act/workflow/envs.txt GITHUB_EVENT_NAME:push GITHUB_EVENT_PATH:/var/run/act/workflow/event.json GITHUB_GRAPHQL_URL:https://api.github.com/graphql GITHUB_HEAD_REF: GITHUB_JOB:Run bandit scan GITHUB_PATH:/var/run/act/workflow/paths.txt GITHUB_REF:refs/heads/main GITHUB_REPOSITORY:SeanWrightSec/bandit GITHUB_REPOSITORY_OWNER:SeanWrightSec GITHUB_RETENTION_DAYS:0 GITHUB_RUN_ID:1 GITHUB_RUN_NUMBER:1 GITHUB_SERVER_URL:https://github.com GITHUB_SHA:2fb7067c7e6be976cc4b5f5f58092cc5b962508c GITHUB_TOKEN: GITHUB_WORKFLOW:bandit GITHUB_WORKSPACE:/tmp/bandit IMAGE_OS:ubuntu20 INPUT_REPO:${{ github.event.repository.name }} INPUT_TARGET:${{ github.workspace }} ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_PERFLOG:/dev/null RUNNER_TRACKING_ID: RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] 
DEBU[0000] Evaluating 'github['event']['repository']['name']' instead of 'github.event.repository.name' 
DEBU[0000] Evaluating 'github['workspace']' instead of 'github.workspace' 
[bandit/Run bandit scan] setupEnv => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache CI:true DEPLOYMENT_BASEPATH:/opt/runner GITHUB_ACTION:bandit GITHUB_ACTIONS:true GITHUB_ACTION_REF: GITHUB_ACTION_REPOSITORY: GITHUB_ACTOR:nektos/act GITHUB_API_URL:https://api.github.com GITHUB_BASE_REF: GITHUB_ENV:/var/run/act/workflow/envs.txt GITHUB_EVENT_NAME:push GITHUB_EVENT_PATH:/var/run/act/workflow/event.json GITHUB_GRAPHQL_URL:https://api.github.com/graphql GITHUB_HEAD_REF: GITHUB_JOB:Run bandit scan GITHUB_PATH:/var/run/act/workflow/paths.txt GITHUB_REF:refs/heads/main GITHUB_REPOSITORY:SeanWrightSec/bandit GITHUB_REPOSITORY_OWNER:SeanWrightSec GITHUB_RETENTION_DAYS:0 GITHUB_RUN_ID:1 GITHUB_RUN_NUMBER:1 GITHUB_SERVER_URL:https://github.com GITHUB_SHA:2fb7067c7e6be976cc4b5f5f58092cc5b962508c GITHUB_TOKEN: GITHUB_WORKFLOW:bandit GITHUB_WORKSPACE:/tmp/bandit IMAGE_OS:ubuntu20 INPUT_REPO: INPUT_TARGET:/tmp/bandit ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_PERFLOG:/dev/null RUNNER_TRACKING_ID: RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root]
[bandit/Run bandit scan] ⭐  Run Bandit
DEBU[0000] Read action &{Python - Bandit  Run a security scan of Python code map[repo:{The name of the current repository true } target:{Scan target true }] map[result:{Scan result }] {docker map[]  Dockerfile [] [] []} { }} from '/tmp/bandit/.github/actions/bandit/action.yaml' 
DEBU[0000] About to run action &{Python - Bandit  Run a security scan of Python code map[repo:{The name of the current repository true } target:{Scan target true }] map[result:{Scan result }] {docker map[]  Dockerfile [] [] []} { }} 
DEBU[0000] type=2 actionDir=/tmp/bandit/.github/actions/bandit actionPath= Workdir=/tmp/bandit ActionCacheDir=/Users/swright/.cache/act actionName=./.github/actions/bandit containerActionDir=/tmp/bandit/.github/actions/bandit 
DEBU[0000] image 'act-github-actions-bandit:latest' for architecture '' already exists 
DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' 
DEBU[0000] using github ref: refs/heads/main            
DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] 
DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' 
DEBU[0000] using github ref: refs/heads/main            
DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] 
DEBU[0000] Evaluating 'github['event']['repository']['name']' instead of 'github.event.repository.name' 
DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' 
DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c 
DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' 
DEBU[0000] using github ref: refs/heads/main            
DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] 
DEBU[0000] Evaluating 'github['workspace']' instead of 'github.workspace' 
DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache CI:true DEPLOYMENT_BASEPATH:/opt/runner GITHUB_ACTION:bandit GITHUB_ACTIONS:true GITHUB_ACTION_REF: GITHUB_ACTION_REPOSITORY: GITHUB_ACTOR:nektos/act GITHUB_API_URL:https://api.github.com GITHUB_BASE_REF: GITHUB_ENV:/var/run/act/workflow/envs.txt GITHUB_EVENT_NAME:push GITHUB_EVENT_PATH:/var/run/act/workflow/event.json GITHUB_GRAPHQL_URL:https://api.github.com/graphql GITHUB_HEAD_REF: GITHUB_JOB:Run bandit scan GITHUB_PATH:/var/run/act/workflow/paths.txt GITHUB_REF:refs/heads/main GITHUB_REPOSITORY:SeanWrightSec/bandit GITHUB_REPOSITORY_OWNER:SeanWrightSec GITHUB_RETENTION_DAYS:0 GITHUB_RUN_ID:1 GITHUB_RUN_NUMBER:1 GITHUB_SERVER_URL:https://github.com GITHUB_SHA:2fb7067c7e6be976cc4b5f5f58092cc5b962508c GITHUB_TOKEN: GITHUB_WORKFLOW:bandit GITHUB_WORKSPACE:/tmp/bandit IMAGE_OS:ubuntu20 INPUT_REPO: INPUT_TARGET:/tmp/bandit ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_PERFLOG:/dev/null RUNNER_TRACKING_ID: RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] 
[bandit/Run bandit scan]   🐳  docker pull act-github-actions-bandit:latest
DEBU[0000] Image exists? true                           
[bandit/Run bandit scan]   🐳  docker create image=act-github-actions-bandit:latest platform= entrypoint=[] cmd=[]
[bandit/Run bandit scan] Created container name=act-bandit-Run-bandit id=85033cce449cf6bd6f7b375f1e09dd3a7d6b96c7162fa1a745611d027bf0d3ff from image act-github-actions-bandit:latest (platform: )
[bandit/Run bandit scan] ENV ==> [GITHUB_HEAD_REF= INPUT_REPO= GITHUB_ACTION_REF= ACT=true GITHUB_RUN_ID=1 GITHUB_ACTOR=nektos/act GITHUB_ENV=/var/run/act/workflow/envs.txt PATH=/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin INPUT_TARGET=/tmp/bandit GITHUB_WORKSPACE=/tmp/bandit GITHUB_PATH=/var/run/act/workflow/paths.txt GITHUB_RETENTION_DAYS=0 GITHUB_REF=refs/heads/main GITHUB_GRAPHQL_URL=https://api.github.com/graphql GITHUB_REPOSITORY_OWNER=SeanWrightSec GITHUB_RUN_NUMBER=1 USER=root GITHUB_API_URL=https://api.github.com GITHUB_ACTION_REPOSITORY= GITHUB_JOB=Run bandit scan CI=true LSB_RELEASE=20.04 RUN_TOOL_CACHE=/opt/hostedtoolcache GITHUB_SHA=2fb7067c7e6be976cc4b5f5f58092cc5b962508c IMAGE_OS=ubuntu20 GITHUB_TOKEN= GITHUB_EVENT_NAME=push RUNNER_PERFLOG=/dev/null ImageOS=ubuntu20 GITHUB_ACTIONS=true GITHUB_WORKFLOW=bandit GITHUB_ACTION=bandit GITHUB_SERVER_URL=https://github.com GITHUB_BASE_REF= AGENT_TOOLSDIRECTORY=/opt/hostedtoolcache GITHUB_EVENT_PATH=/var/run/act/workflow/event.json RUNNER_USER=root RUNNER_TRACKING_ID= DEPLOYMENT_BASEPATH=/opt/runner GITHUB_REPOSITORY=SeanWrightSec/bandit RUNNER_TOOL_CACHE=/opt/hostedtoolcache RUNNER_OS=Linux RUNNER_TEMP=/tmp]
[bandit/Run bandit scan]   🐳  docker run image=act-github-actions-bandit:latest platform= entrypoint=[] cmd=[]
[bandit/Run bandit scan] Starting container: 85033cce449cf6bd6f7b375f1e09dd3a7d6b96c7162fa1a745611d027bf0d3ff
[bandit/Run bandit scan] Started container: 85033cce449cf6bd6f7b375f1e09dd3a7d6b96c7162fa1a745611d027bf0d3ff
| [main]	INFO	profile include tests: None
| [main]	INFO	profile exclude tests: None
| [main]	INFO	cli include tests: None
| [main]	INFO	cli exclude tests: None
| [main]	INFO	running on Python 3.9.6
| [text]	INFO	Text output written to file: /tmp/scan
| /entrypoint.sh: line 10: /var/run/act/workflow/envs.txt: No such file or directory
[bandit/Run bandit scan] Return status: 1
[bandit/Run bandit scan] Removed container: 85033cce449cf6bd6f7b375f1e09dd3a7d6b96c7162fa1a745611d027bf0d3ff
[bandit/Run bandit scan]   ❌  Failure - Bandit
DEBU[0001] exit with `FAILURE`: 1                       
Error: exit with `FAILURE`: 1
Originally created by @SeanWrightSec on GitHub (Jul 1, 2021). Original GitHub issue: https://github.com/nektos/act/issues/747 <!-- - Make sure you are able to reproduce it on the [latest version](https://github.com/nektos/act/releases) - Search the existing issues. - Refer to [README](https://github.com/nektos/act/blob/master/README.md). --> ## System information <!-- - Operating System: < Windows | Linux | macOS | etc... > - Architecture: < x64 (64-bit) | x86 (32-bit) | arm64 (64-bit) | arm (32-bit) | etc... > - Apple M1: < yes | no > - Docker version: < output of `docker system info -f "{{.ServerVersion}}"` > - Docker image used in `act`: < can be omitted if it's included in log > - `act` version: < output of `act --version`, if you've built `act` yourself, please provide commit hash > --> - Operating System: macOS - Architecture: arm64 - Apple M1: yes - Docker version: 20.10.7 - Docker image used in `act`: catthehacker/ubuntu:act-latest - `act` version: 0.2.23 ## Expected behaviour <!-- - Describe how whole process should go and finish --> I've attempting to set an environment variable within an entrypoint script in an action: ``` echo 'RESULT<<EOF' >> $GITHUB_ENV cat /etc/hosts >> $GITHUB_ENV echo 'EOF' >> $GITHUB_ENV ``` ## Actual behaviour <!-- - Describe the issue --> When running this action I get the following error: `/entrypoint.sh: line 10: /var/run/act/workflow/envs.txt: No such file or directory` ## Workflow and/or repository <!-- - Provide workflow with which we can reproduce the issue OR - Provide link to your GitHub repository that contains the workflow <details> <summary>workflow</summary> ```none name: bandit on: push jobs: label: name: "Run bandit scan" runs-on: ubuntu-latest steps: - name: "Checkout" uses: "actions/checkout@v2" - name: "Bandit" id: "bandit" uses: "./.github/actions/bandit/" env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: repo: ${{ github.event.repository.name }} target: ${{ github.workspace }} ``` </details> ## Steps to reproduce <!-- - Make sure to include full command with parameters you used to run `act`, example: 1. Clone example repo (https://github.com/cplee/github-actions-demo) 2. Enter cloned repo directory 3. Run `act -s SUPER_SECRET=im-a-value` --> 1. Clone repo https://github.com/SeanWrightSec/bandit.git 2. Enter cloned repo directory 3. Run `act` ## `act` output <!-- - Use `act` with `-v`/`--verbose` and paste output from your terminal in code block below --> <details> <summary>Log</summary> ```none DEBU[0000] Loading environment from /tmp/bandit/.env DEBU[0000] Loading secrets from /tmp/bandit/.secrets DEBU[0000] Loading workflows from '/tmp/bandit/.github/workflows' DEBU[0000] Loading workflows recursively DEBU[0000] Found workflow 'main.yml' in '/tmp/bandit/.github/workflows/main.yml' DEBU[0000] Reading workflow '/tmp/bandit/.github/workflows/main.yml' DEBU[0000] Correcting if statements '/tmp/bandit/.github/workflows/main.yml' DEBU[0000] Planning event: push DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' DEBU[0000] using github ref: refs/heads/main DEBU[0000] context env => map[ACT:true] [bandit/Run bandit scan] 🚀 Start image=catthehacker/ubuntu:act-latest DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' DEBU[0000] using github ref: refs/heads/main [bandit/Run bandit scan] 🐳 docker pull catthehacker/ubuntu:act-latest DEBU[0000] Image exists? true [bandit/Run bandit scan] Removed container: b6d8108d3ab5a7f66a0c9705fc06edb419df7338853b8fe568641d81b6f9a38e [bandit/Run bandit scan] 🐳 docker volume rm act-bandit-Run-bandit-scan [bandit/Run bandit scan] 🐳 docker create image=catthehacker/ubuntu:act-latest platform= entrypoint=["/usr/bin/tail" "-f" "/dev/null"] cmd=[] [bandit/Run bandit scan] Created container name=act-bandit-Run-bandit-scan id=fa2f2a536271bea7ba5d01e7aa0599daf17202a3309d430c2f4182b5a815d8f9 from image catthehacker/ubuntu:act-latest (platform: ) [bandit/Run bandit scan] ENV ==> [RUNNER_TOOL_CACHE=/opt/hostedtoolcache RUNNER_OS=Linux RUNNER_TEMP=/tmp] [bandit/Run bandit scan] 🐳 docker run image=catthehacker/ubuntu:act-latest platform= entrypoint=["/usr/bin/tail" "-f" "/dev/null"] cmd=[] [bandit/Run bandit scan] Starting container: fa2f2a536271bea7ba5d01e7aa0599daf17202a3309d430c2f4182b5a815d8f9 [bandit/Run bandit scan] Started container: fa2f2a536271bea7ba5d01e7aa0599daf17202a3309d430c2f4182b5a815d8f9 [bandit/Run bandit scan] 🐳 docker exec cmd=[mkdir -m 0777 -p /var/run/act] user=root [bandit/Run bandit scan] Exec command '[mkdir -m 0777 -p /var/run/act]' [bandit/Run bandit scan] 🐳 docker cp src=/tmp/bandit/. dst=/tmp/bandit [bandit/Run bandit scan] 🐳 docker exec cmd=[mkdir -p /tmp/bandit] user= [bandit/Run bandit scan] Exec command '[mkdir -p /tmp/bandit]' DEBU[0000] Writing tarball /var/folders/ty/trwr80zs6_g38vlmmkh3xrhm0000gn/T/act575372720 from /tmp/bandit/. DEBU[0000] Stripping prefix:/tmp/bandit/ src:/tmp/bandit/. [bandit/Run bandit scan] Extracting content from '/var/folders/ty/trwr80zs6_g38vlmmkh3xrhm0000gn/T/act575372720' to '/tmp/bandit' DEBU[0000] Writing entry to tarball workflow/event.json len:2 DEBU[0000] Writing entry to tarball workflow/envs.txt len:0 DEBU[0000] Writing entry to tarball workflow/paths.txt len:0 [bandit/Run bandit scan] Extracting content to '/var/run/act/' DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' DEBU[0000] using github ref: refs/heads/main DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' DEBU[0000] using github ref: refs/heads/main DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache CI:true DEPLOYMENT_BASEPATH:/opt/runner GITHUB_ACTION:0 GITHUB_ACTIONS:true GITHUB_ACTION_REF: GITHUB_ACTION_REPOSITORY: GITHUB_ACTOR:nektos/act GITHUB_API_URL:https://api.github.com GITHUB_BASE_REF: GITHUB_ENV:/var/run/act/workflow/envs.txt GITHUB_EVENT_NAME:push GITHUB_EVENT_PATH:/var/run/act/workflow/event.json GITHUB_GRAPHQL_URL:https://api.github.com/graphql GITHUB_HEAD_REF: GITHUB_JOB:Run bandit scan GITHUB_PATH:/var/run/act/workflow/paths.txt GITHUB_REF:refs/heads/main GITHUB_REPOSITORY:SeanWrightSec/bandit GITHUB_REPOSITORY_OWNER:SeanWrightSec GITHUB_RETENTION_DAYS:0 GITHUB_RUN_ID:1 GITHUB_RUN_NUMBER:1 GITHUB_SERVER_URL:https://github.com GITHUB_SHA:2fb7067c7e6be976cc4b5f5f58092cc5b962508c GITHUB_TOKEN: GITHUB_WORKFLOW:bandit GITHUB_WORKSPACE:/tmp/bandit IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_PERFLOG:/dev/null RUNNER_TRACKING_ID: RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] [bandit/Run bandit scan] setupEnv => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache CI:true DEPLOYMENT_BASEPATH:/opt/runner GITHUB_ACTION:0 GITHUB_ACTIONS:true GITHUB_ACTION_REF: GITHUB_ACTION_REPOSITORY: GITHUB_ACTOR:nektos/act GITHUB_API_URL:https://api.github.com GITHUB_BASE_REF: GITHUB_ENV:/var/run/act/workflow/envs.txt GITHUB_EVENT_NAME:push GITHUB_EVENT_PATH:/var/run/act/workflow/event.json GITHUB_GRAPHQL_URL:https://api.github.com/graphql GITHUB_HEAD_REF: GITHUB_JOB:Run bandit scan GITHUB_PATH:/var/run/act/workflow/paths.txt GITHUB_REF:refs/heads/main GITHUB_REPOSITORY:SeanWrightSec/bandit GITHUB_REPOSITORY_OWNER:SeanWrightSec GITHUB_RETENTION_DAYS:0 GITHUB_RUN_ID:1 GITHUB_RUN_NUMBER:1 GITHUB_SERVER_URL:https://github.com GITHUB_SHA:2fb7067c7e6be976cc4b5f5f58092cc5b962508c GITHUB_TOKEN: GITHUB_WORKFLOW:bandit GITHUB_WORKSPACE:/tmp/bandit IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_PERFLOG:/dev/null RUNNER_TRACKING_ID: RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] [bandit/Run bandit scan] ⭐ Run Checkout DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' DEBU[0000] using github ref: refs/heads/main [bandit/Run bandit scan] Skipping local actions/checkout because workdir was already copied [bandit/Run bandit scan] ✅ Success - Checkout DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' DEBU[0000] using github ref: refs/heads/main DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' DEBU[0000] using github ref: refs/heads/main DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' DEBU[0000] using github ref: refs/heads/main DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] DEBU[0000] Evaluating 'github['event']['repository']['name']' instead of 'github.event.repository.name' DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' DEBU[0000] using github ref: refs/heads/main DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] DEBU[0000] Evaluating 'github['workspace']' instead of 'github.workspace' DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache CI:true DEPLOYMENT_BASEPATH:/opt/runner GITHUB_ACTION:bandit GITHUB_ACTIONS:true GITHUB_ACTION_REF: GITHUB_ACTION_REPOSITORY: GITHUB_ACTOR:nektos/act GITHUB_API_URL:https://api.github.com GITHUB_BASE_REF: GITHUB_ENV:/var/run/act/workflow/envs.txt GITHUB_EVENT_NAME:push GITHUB_EVENT_PATH:/var/run/act/workflow/event.json GITHUB_GRAPHQL_URL:https://api.github.com/graphql GITHUB_HEAD_REF: GITHUB_JOB:Run bandit scan GITHUB_PATH:/var/run/act/workflow/paths.txt GITHUB_REF:refs/heads/main GITHUB_REPOSITORY:SeanWrightSec/bandit GITHUB_REPOSITORY_OWNER:SeanWrightSec GITHUB_RETENTION_DAYS:0 GITHUB_RUN_ID:1 GITHUB_RUN_NUMBER:1 GITHUB_SERVER_URL:https://github.com GITHUB_SHA:2fb7067c7e6be976cc4b5f5f58092cc5b962508c GITHUB_TOKEN: GITHUB_WORKFLOW:bandit GITHUB_WORKSPACE:/tmp/bandit IMAGE_OS:ubuntu20 INPUT_REPO:${{ github.event.repository.name }} INPUT_TARGET:${{ github.workspace }} ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_PERFLOG:/dev/null RUNNER_TRACKING_ID: RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] DEBU[0000] Evaluating 'github['event']['repository']['name']' instead of 'github.event.repository.name' DEBU[0000] Evaluating 'github['workspace']' instead of 'github.workspace' [bandit/Run bandit scan] setupEnv => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache CI:true DEPLOYMENT_BASEPATH:/opt/runner GITHUB_ACTION:bandit GITHUB_ACTIONS:true GITHUB_ACTION_REF: GITHUB_ACTION_REPOSITORY: GITHUB_ACTOR:nektos/act GITHUB_API_URL:https://api.github.com GITHUB_BASE_REF: GITHUB_ENV:/var/run/act/workflow/envs.txt GITHUB_EVENT_NAME:push GITHUB_EVENT_PATH:/var/run/act/workflow/event.json GITHUB_GRAPHQL_URL:https://api.github.com/graphql GITHUB_HEAD_REF: GITHUB_JOB:Run bandit scan GITHUB_PATH:/var/run/act/workflow/paths.txt GITHUB_REF:refs/heads/main GITHUB_REPOSITORY:SeanWrightSec/bandit GITHUB_REPOSITORY_OWNER:SeanWrightSec GITHUB_RETENTION_DAYS:0 GITHUB_RUN_ID:1 GITHUB_RUN_NUMBER:1 GITHUB_SERVER_URL:https://github.com GITHUB_SHA:2fb7067c7e6be976cc4b5f5f58092cc5b962508c GITHUB_TOKEN: GITHUB_WORKFLOW:bandit GITHUB_WORKSPACE:/tmp/bandit IMAGE_OS:ubuntu20 INPUT_REPO: INPUT_TARGET:/tmp/bandit ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_PERFLOG:/dev/null RUNNER_TRACKING_ID: RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] [bandit/Run bandit scan] ⭐ Run Bandit DEBU[0000] Read action &{Python - Bandit Run a security scan of Python code map[repo:{The name of the current repository true } target:{Scan target true }] map[result:{Scan result }] {docker map[] Dockerfile [] [] []} { }} from '/tmp/bandit/.github/actions/bandit/action.yaml' DEBU[0000] About to run action &{Python - Bandit Run a security scan of Python code map[repo:{The name of the current repository true } target:{Scan target true }] map[result:{Scan result }] {docker map[] Dockerfile [] [] []} { }} DEBU[0000] type=2 actionDir=/tmp/bandit/.github/actions/bandit actionPath= Workdir=/tmp/bandit ActionCacheDir=/Users/swright/.cache/act actionName=./.github/actions/bandit containerActionDir=/tmp/bandit/.github/actions/bandit DEBU[0000] image 'act-github-actions-bandit:latest' for architecture '' already exists DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' DEBU[0000] using github ref: refs/heads/main DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' DEBU[0000] using github ref: refs/heads/main DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] DEBU[0000] Evaluating 'github['event']['repository']['name']' instead of 'github.event.repository.name' DEBU[0000] Loading slug from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] Loading revision from git directory '/tmp/bandit/.git' DEBU[0000] Found revision: 2fb7067c7e6be976cc4b5f5f58092cc5b962508c DEBU[0000] HEAD points to '2fb7067c7e6be976cc4b5f5f58092cc5b962508c' DEBU[0000] using github ref: refs/heads/main DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache DEPLOYMENT_BASEPATH:/opt/runner IMAGE_OS:ubuntu20 ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] DEBU[0000] Evaluating 'github['workspace']' instead of 'github.workspace' DEBU[0000] context env => map[ACT:true AGENT_TOOLSDIRECTORY:/opt/hostedtoolcache CI:true DEPLOYMENT_BASEPATH:/opt/runner GITHUB_ACTION:bandit GITHUB_ACTIONS:true GITHUB_ACTION_REF: GITHUB_ACTION_REPOSITORY: GITHUB_ACTOR:nektos/act GITHUB_API_URL:https://api.github.com GITHUB_BASE_REF: GITHUB_ENV:/var/run/act/workflow/envs.txt GITHUB_EVENT_NAME:push GITHUB_EVENT_PATH:/var/run/act/workflow/event.json GITHUB_GRAPHQL_URL:https://api.github.com/graphql GITHUB_HEAD_REF: GITHUB_JOB:Run bandit scan GITHUB_PATH:/var/run/act/workflow/paths.txt GITHUB_REF:refs/heads/main GITHUB_REPOSITORY:SeanWrightSec/bandit GITHUB_REPOSITORY_OWNER:SeanWrightSec GITHUB_RETENTION_DAYS:0 GITHUB_RUN_ID:1 GITHUB_RUN_NUMBER:1 GITHUB_SERVER_URL:https://github.com GITHUB_SHA:2fb7067c7e6be976cc4b5f5f58092cc5b962508c GITHUB_TOKEN: GITHUB_WORKFLOW:bandit GITHUB_WORKSPACE:/tmp/bandit IMAGE_OS:ubuntu20 INPUT_REPO: INPUT_TARGET:/tmp/bandit ImageOS:ubuntu20 LSB_RELEASE:20.04 PATH:/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin RUNNER_PERFLOG:/dev/null RUNNER_TRACKING_ID: RUNNER_USER:root RUN_TOOL_CACHE:/opt/hostedtoolcache USER:root] [bandit/Run bandit scan] 🐳 docker pull act-github-actions-bandit:latest DEBU[0000] Image exists? true [bandit/Run bandit scan] 🐳 docker create image=act-github-actions-bandit:latest platform= entrypoint=[] cmd=[] [bandit/Run bandit scan] Created container name=act-bandit-Run-bandit id=85033cce449cf6bd6f7b375f1e09dd3a7d6b96c7162fa1a745611d027bf0d3ff from image act-github-actions-bandit:latest (platform: ) [bandit/Run bandit scan] ENV ==> [GITHUB_HEAD_REF= INPUT_REPO= GITHUB_ACTION_REF= ACT=true GITHUB_RUN_ID=1 GITHUB_ACTOR=nektos/act GITHUB_ENV=/var/run/act/workflow/envs.txt PATH=/opt/hostedtoolcache/node/14.17.1/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin INPUT_TARGET=/tmp/bandit GITHUB_WORKSPACE=/tmp/bandit GITHUB_PATH=/var/run/act/workflow/paths.txt GITHUB_RETENTION_DAYS=0 GITHUB_REF=refs/heads/main GITHUB_GRAPHQL_URL=https://api.github.com/graphql GITHUB_REPOSITORY_OWNER=SeanWrightSec GITHUB_RUN_NUMBER=1 USER=root GITHUB_API_URL=https://api.github.com GITHUB_ACTION_REPOSITORY= GITHUB_JOB=Run bandit scan CI=true LSB_RELEASE=20.04 RUN_TOOL_CACHE=/opt/hostedtoolcache GITHUB_SHA=2fb7067c7e6be976cc4b5f5f58092cc5b962508c IMAGE_OS=ubuntu20 GITHUB_TOKEN= GITHUB_EVENT_NAME=push RUNNER_PERFLOG=/dev/null ImageOS=ubuntu20 GITHUB_ACTIONS=true GITHUB_WORKFLOW=bandit GITHUB_ACTION=bandit GITHUB_SERVER_URL=https://github.com GITHUB_BASE_REF= AGENT_TOOLSDIRECTORY=/opt/hostedtoolcache GITHUB_EVENT_PATH=/var/run/act/workflow/event.json RUNNER_USER=root RUNNER_TRACKING_ID= DEPLOYMENT_BASEPATH=/opt/runner GITHUB_REPOSITORY=SeanWrightSec/bandit RUNNER_TOOL_CACHE=/opt/hostedtoolcache RUNNER_OS=Linux RUNNER_TEMP=/tmp] [bandit/Run bandit scan] 🐳 docker run image=act-github-actions-bandit:latest platform= entrypoint=[] cmd=[] [bandit/Run bandit scan] Starting container: 85033cce449cf6bd6f7b375f1e09dd3a7d6b96c7162fa1a745611d027bf0d3ff [bandit/Run bandit scan] Started container: 85033cce449cf6bd6f7b375f1e09dd3a7d6b96c7162fa1a745611d027bf0d3ff | [main] INFO profile include tests: None | [main] INFO profile exclude tests: None | [main] INFO cli include tests: None | [main] INFO cli exclude tests: None | [main] INFO running on Python 3.9.6 | [text] INFO Text output written to file: /tmp/scan | /entrypoint.sh: line 10: /var/run/act/workflow/envs.txt: No such file or directory [bandit/Run bandit scan] Return status: 1 [bandit/Run bandit scan] Removed container: 85033cce449cf6bd6f7b375f1e09dd3a7d6b96c7162fa1a745611d027bf0d3ff [bandit/Run bandit scan] ❌ Failure - Bandit DEBU[0001] exit with `FAILURE`: 1 Error: exit with `FAILURE`: 1 ``` </details>
kerem 2026-03-01 21:43:42 +03:00
Author
Owner

@SeanWrightSec commented on GitHub (Jul 1, 2021):

When I had a look at the Docker container for act, the file does appear to be there:

root@docker-desktop:/var/run/act/workflow# ls -l
total 4
-rw-rw-rw- 1 root root 0 Jan  1  1970 envs.txt
-rw-r--r-- 1 root root 2 Jan  1  1970 event.json
-rw-rw-rw- 1 root root 0 Jan  1  1970 paths.txt
root@docker-desktop:/var/run/act/workflow# cat envs.txt 
root@docker-desktop:/var/run/act/workflow#
<!-- gh-comment-id:872576038 --> @SeanWrightSec commented on GitHub (Jul 1, 2021): When I had a look at the Docker container for act, the file does appear to be there: ```none root@docker-desktop:/var/run/act/workflow# ls -l total 4 -rw-rw-rw- 1 root root 0 Jan 1 1970 envs.txt -rw-r--r-- 1 root root 2 Jan 1 1970 event.json -rw-rw-rw- 1 root root 0 Jan 1 1970 paths.txt root@docker-desktop:/var/run/act/workflow# cat envs.txt root@docker-desktop:/var/run/act/workflow# ```
Author
Owner

@github-actions[bot] commented on GitHub (Aug 1, 2021):

Issue is stale and will be closed in 14 days unless there is new activity

<!-- gh-comment-id:890419316 --> @github-actions[bot] commented on GitHub (Aug 1, 2021): Issue is stale and will be closed in 14 days unless there is new activity
Author
Owner

@catthehacker commented on GitHub (Aug 9, 2021):

I think that's because we don't mount /var/run/act into nested containers but will need to take a look at code

<!-- gh-comment-id:895543382 --> @catthehacker commented on GitHub (Aug 9, 2021): I think that's because we don't mount `/var/run/act` into nested containers but will need to take a look at code
Author
Owner

@github-actions[bot] commented on GitHub (Sep 9, 2021):

Issue is stale and will be closed in 14 days unless there is new activity

<!-- gh-comment-id:915653917 --> @github-actions[bot] commented on GitHub (Sep 9, 2021): Issue is stale and will be closed in 14 days unless there is new activity
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/act#469
No description provided.