mirror of
https://github.com/actions/runner.git
synced 2025-12-11 21:06:55 +00:00
Added ability to run Dockerfile.SUFFIX ContainerAction (#1738)
* Added ability to run Dockerfile.SUFFIX ContainerAction * Extracted IsDockerFile method * reformatted, moved from index to Last() * extracted IsDockerfile to DockerUtil with L0 * added check for IsDockerfile to account for docker:// * updated test to clearly show path/dockerfile:tag * fail if Data.Image is not Dockerfile or docker://[image]
This commit is contained in:
@@ -1004,7 +1004,7 @@ namespace GitHub.Runner.Worker
|
||||
if (actionDefinitionData.Execution.ExecutionType == ActionExecutionType.Container)
|
||||
{
|
||||
var containerAction = actionDefinitionData.Execution as ContainerActionExecutionData;
|
||||
if (containerAction.Image.EndsWith("Dockerfile") || containerAction.Image.EndsWith("dockerfile"))
|
||||
if (DockerUtil.IsDockerfile(containerAction.Image))
|
||||
{
|
||||
var dockerFileFullPath = Path.Combine(actionEntryDirectory, containerAction.Image);
|
||||
executionContext.Debug($"Dockerfile for action: '{dockerFileFullPath}'.");
|
||||
|
||||
Reference in New Issue
Block a user