This commit is contained in:
TingluoHuang
2021-10-14 16:29:59 -04:00
parent f37e9f80a6
commit 7128998d77
4 changed files with 201 additions and 52 deletions

View File

@@ -29,12 +29,34 @@ namespace GitHub.Runner.Worker
public ContainersCreationInput CreationInput { get; set; }
[DataMember]
public object JobContainerExecInput { get; set; }
public JobContainerExecInput ExecInput { get; set; }
[DataMember]
public ContainersRemoveInput RemoveInput { get; set; }
}
[DataContract]
public class JobContainerExecInput
{
[DataMember]
public ContainerInfo JobContainer { get; set; }
[DataMember]
public string WorkingDirectory { get; set; }
[DataMember]
public string FileName { get; set; }
[DataMember]
public string Arguments { get; set; }
[DataMember]
public List<string> EnvironmentKeys { get; set; }
}
[DataContract]
public class ContainersCreationInput
{
@@ -192,6 +214,7 @@ namespace GitHub.Runner.Worker
{
executionContext.JobContext.Container["network"] = new StringContextData(podmanOutput.CreationOutput.Network);
executionContext.JobContext.Container["id"] = new StringContextData(podmanOutput.CreationOutput.JobContainerId);
executionContext.Global.Container.ContainerId = podmanOutput.CreationOutput.JobContainerId;
}
}
else