Hello Community. This is my directory ```my_projec...
# ask-the-community
l
Hello Community. This is my directory
Copy code
my_project# tree .
.
├── Dockerfile
├── LICENSE
├── README.md
├── __pycache__
│   └── remote.cpython-38.pyc
├── flyte-package.tgz
├── remote.py
├── requirements.txt
└── workflows
    ├── __init__.py
    ├── __pycache__
    │   ├── __init__.cpython-38.pyc
    │   └── example.cpython-38.pyc
    └── example.py
I have use the command line
Copy code
docker build -t workflow-test .
This is my "docker image ls"
Copy code
my_project# docker image ls
REPOSITORY                                    TAG                                            IMAGE ID       CREATED         SIZE
workflow-test                                 latest                                         4d603227435c   9 minutes ago   1.14GB
apache/submarine                              jupyter-notebook-gpu-0.8.0-SNAPSHOT            9b87bfcac94e   6 days ago      6.37GB
apache/submarine                              jupyter-notebook-0.8.0-SNAPSHOT                a9c9fb6cf1d6   6 days ago      6.15GB
nvidia/cuda                                   12.2.0-base-ubuntu20.04                        d9270b9c551d   8 days ago      241MB
<http://cr.flyte.org/flyteorg/flyte-sandbox-bundled|cr.flyte.org/flyteorg/flyte-sandbox-bundled>   sha-1ae254f8683699b68ecddc89d775fc5d39cc3d84   ca7cf64c101b   3 weeks ago     2.17GB
<http://gcr.io/k8s-minikube/kicbase|gcr.io/k8s-minikube/kicbase>                   v0.0.39                                        67a4b1138d2d   3 months ago    1.05GB
I am wondering that how do I specify my image_config in the code ?
Copy code
from flytekit.remote import FlyteRemote
from flytekit.configuration import Config
from workflows.example import wf

# TODO Build Image by the docker file

remote = FlyteRemote(config=Config.auto(), \
                      default_project="flytesnacks", default_domain="development")

execution = remote.execute(wf, inputs={"name": "Kermit"}, image_config="4d603227435c")


print(f"Execution url: {remote.generate_console_url(execution)}")
Thank you very much !
s
@L godlike, you need to push your Docker image to a registry. Here's how you can specify an image:
Copy code
wf = remote.register_script(
    feast_workflow,
    image_config=ImageConfig.from_images(
        "<http://ghcr.io/flyteorg/flytecookbook:feast_integration-latest|ghcr.io/flyteorg/flytecookbook:feast_integration-latest>"
    ),
    version="v2",
    source_path="../",
    module_name="feast_workflow",
)
l
Thank you very much, I will try again
Hi, I just change my code to
Copy code
remote = FlyteRemote(config=Config.auto(), \
                      default_project="flytesnacks", default_domain="development")


execution = remote.execute(wf, \
                           inputs={"name": "Kermit"},\
                           image_config=ImageConfig("futureoutlier/flyte-practice:latest"))
and it works ! Thanks you for helping me !