The ENTRYPOINT in the dockerfile is being prepended to the docker command. The implementation.container.command should override this.
Instead the container is running
import kfp.dsl as dsl
import kfp
import kfp.local as local
import kfp.components as components
import yaml
local.init(runner=local.DockerRunner())
NAMESPACE = 'kubeflow-zeroone-gg'
katib_experiment_launcher_op = components.load_component_from_file('try_kubeflow/components/katib_experiment_launcher.yaml')
def get_experiment():
with open('try_kubeflow/experiments/experiment.yaml') as f:
return yaml.load(f, Loader=yaml.CLoader)
@dsl.pipeline()
def my_pipeline():
op = katib_experiment_launcher_op(
experiment_name='experiment-fashion',
experiment_namespace=NAMESPACE,
experiment_spec=get_experiment()
).set_display_name('train')
if __name__ == '__main__':
my_pipeline()
Copied from an example component in this repo.
name: Katib - Launch Experiment
description: Katib Experiment launcher
inputs:
- {name: Experiment Name, type: String, default: '', description: 'Experiment name'}
- {name: Experiment Namespace, type: String, default: anonymous, description: 'Experiment namespace'}
- {name: Experiment Spec, type: JsonObject, default: '{}', description: 'Experiment specification in dict format'}
- {name: Experiment Timeout Minutes, type: Integer, default: 1440, description: 'Time in minutes to wait for the Experiment to complete'}
- {name: Delete Finished Experiment, type: Bool, default: 'True', description: 'Whether to delete the Experiment after it is finished'}
outputs:
- {name: Best Parameter Set, type: JsonObject, description: 'The hyperparameter set of the best Experiment Trial'}
implementation:
container:
image: docker.io/kubeflowkatib/kubeflow-pipelines-launcher
command: [python, src/launch_experiment.py]
args: [
--experiment-name, {inputValue: Experiment Name},
--experiment-namespace, {inputValue: Experiment Namespace},
--experiment-spec, {inputValue: Experiment Spec},
--experiment-timeout-minutes, {inputValue: Experiment Timeout Minutes},
--delete-after-done, {inputValue: Delete Finished Experiment},
--output-file, {outputPath: Best Parameter Set},
]
Expected result
Running locally should run in the same way as running the pipeline on the api-server.
The component yaml file has specified a implementation.container.command. This field should override whatever set as the entrypoint in the Dockerfile.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Environment
Steps to reproduce
The ENTRYPOINT in the dockerfile is being prepended to the docker command. The
implementation.container.command
should override this. Instead the container is runningCopied from an example component in this repo.
Expected result
Running locally should run in the same way as running the pipeline on the api-server. The component yaml file has specified a
implementation.container.command
. This field should override whatever set as the entrypoint in the Dockerfile.Materials and reference
Labels
/area sdk
Impacted by this bug? Give it a 👍.