Volumes
Argo Workflows allows you to mount volumes from many different sources. Hera provides wrappper classes for all of the first-party Kubernetes volumes (such as Volume and EmptyDirVolume), as well as third-party volumes (such as CinderVolume).
The hera.workflows.volume module provides all Argo volume types that can be used via Hera.
Volume
Volume represents a basic, dynamic, volume representation.
This Volume cannot only be instantiated to be used for mounting purposes but also for dynamically privisioning
volumes in K8s. When the volume is used a corresponding persistent volume claim is also created on workflow
submission.
Source code in src/hera/workflows/volume.py
534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 | |
AccessMode
A representations of the volume access modes for Kubernetes.
Notes
See: access modes docs for more information.
Source code in src/hera/workflows/volume.py
read_write_many
The volume can be mounted as read-write by many nodes
read_write_once
The volume can be mounted as read-write by a single node. ReadWriteOnce access mode still can allow multiple pods to access the volume when the pods are running on the same node
read_write_once_pod
The volume can be mounted as read-write by a single Pod. Use ReadWriteOncePod access mode if you want to ensure that only one pod across whole cluster can read that PVC or write to it. This is only supported for CSI volumes and Kubernetes version 1.22+.