act "upload-artifact" fails without an artifact server locally
actions/upload-artifact and download-artifact talk to a GitHub artifact service. act does not run one by default, so upload fails or is skipped and a later download finds nothing. act can start a local artifact server if you give it a path.
What this error means
Under act, upload-artifact errors with a missing runtime URL/token, or download-artifact finds no artifact because none was stored.
Error: Unable to get the ACTIONS_RUNTIME_URL env variable
Error: Create Artifact Container failed: the artifact server is not configuredCommon causes
No artifact server is running
The runtime URL and token that upload-artifact needs come from the GitHub artifact service, which act does not provide by default.
Download has nothing to fetch
If upload was a no-op, a subsequent download-artifact in the same run finds no matching artifact.
How to fix it
Start act's artifact server
Give act an artifact server path so upload and download work locally.
act --artifact-server-path /tmp/act-artifacts -j buildGate artifact steps under act
Skip artifact upload/download locally when you only need to validate the build.
- uses: actions/upload-artifact@v4
if: ${{ !env.ACT }}How to prevent it
- Pass
--artifact-server-pathwhen a workflow uploads or downloads artifacts. - Gate artifact steps with
if: !env.ACTwhen not testing them. - Validate full artifact retention and cross-job download on GitHub.