Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add requirements to imageSpec #1698

Merged
merged 7 commits into from
Jul 5, 2023
Merged

Add requirements to imageSpec #1698

merged 7 commits into from
Jul 5, 2023

Conversation

pingsutw
Copy link
Member

TL;DR

Add support passing requirements.txt to image spec.

Type

  • Bug Fix
  • Feature
  • Plugin

Are all requirements met?

  • Code completed
  • Smoke tested
  • Unit tests added
  • Code documentation added
  • Any pending items have an associated Issue

Complete description

Example

from flytekit import task, workflow, ImageSpec

new_flytekit = "git+https://github.com/flyteorg/flytekit@01f2d63221467face8d35ed0af5308bbb3e66eaa"
image = ImageSpec(registry="pingsutw", packages=["pandas", new_flytekit], apt_packages=["git"], requirements="requirement.txt")


@task(container_image=image)
def bar():
    print("hello")
    print("hello")


@workflow
def wf() -> str:
    bar()
    return "hi"


if __name__ == '__main__':
    wf()

Tracking Issue

NA

Follow-up issue

NA

@pingsutw pingsutw marked this pull request as draft June 19, 2023 21:06
pingsutw added 4 commits June 19, 2023 20:00
Signed-off-by: Kevin Su <[email protected]>
Signed-off-by: Kevin Su <[email protected]>
Signed-off-by: Kevin Su <[email protected]>
Signed-off-by: Kevin Su <[email protected]>
@pingsutw pingsutw marked this pull request as ready for review June 26, 2023 21:26
Signed-off-by: Kevin Su <[email protected]>
@cosmicBboy
Copy link
Contributor

is this ready to go @pingsutw ?

@pingsutw pingsutw merged commit da21782 into master Jul 5, 2023
fg91 pushed a commit that referenced this pull request Aug 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants