Core concepts
Swale runs workflows of containers: you define each task once as a container image, and a YAML workflow says which tasks run, in what order, and on which compute type. Each run starts every task that runs an image on compute allocated to that task at its compute type, gives the tasks one shared workspace, meters what they use, and keeps the files they push in versioned repositories.
Entity hierarchy
Everything on the platform organizes into a clear hierarchy:
Account (personal, or an organization)
├─ Project
│ ├─ Repository
│ ├─ Workflow definition
│ │ └─ Run
│ │ └─ Task (instance of a task definition)
│ └─ Project secret
├─ Account secret
└─ Task definition
- Account — the top-level owner of everything below it. An account is personal, the one you sign in with, or an organization, which several people share; see Organizations, members, and teams.
- Project — a workspace inside an account. Projects hold workflows, repositories, and project secrets.
- Account secret and task definition — belong to the account rather than to one project: an account secret is shared with the projects it allows, and a task definition can be used by any workflow in the account, or in every account once it is public.
- Workflow definition — a YAML document that describes the sequence of tasks to run.
- Run — a single execution of a workflow definition. Each run is independent and has its own status and outputs.
- Task — an individual unit of work within a run. Each task runs a container image with optional arguments, except control tasks (if and
for_each), which move the run between blocks.
Projects
A project's name is part of the address of every page in it. Renaming a project changes only its name: its runs, repositories, workflows, secrets and team associations stay with it, including runs still in progress, and its pages move to the new name.
Unless the new name differs from the former one only in capitalisation or spacing, when both name the same project, links to the former name stop resolving and the former name is free for another project. Teams stay associated with the renamed project, so their Contributors keep their access, and a project that later takes the former name is not shared with them.
Workflow definitions vs. runs
A workflow definition is a template. It stays static until you upload a new version.
A run is an instance of that template started with a specific set of inputs. Runs started from the same definition are independent of one another.
How many runs an account can have in progress at once is limited, whichever definitions they come from, and so is how many of their tasks it can run at once; see Limits and quotas.
Task definitions vs. workflow task references
A task definition is a reusable, versioned container specification that lives on the platform. It declares a container image, optional arguments, named inputs, and optional named outputs; see Task definition syntax.
A workflow task reference (the uses field in workflow YAML) points to a task definition identifier and version. When a workflow is created or updated, the platform resolves each uses reference to an exact task definition version — the most recently published one at that moment when the reference omits a version — and the workflow's runs use that version until the workflow is updated again.
Compute types
Each workflow and each task can specify a compute type, which names the compute a task is allocated:
| Compute type | Shown as | Resources | Memory a task can use | Task storage |
|---|---|---|---|---|
cpu-2 | CPU x 2 | 2 vCPUs, 8 GiB memory | At least 4 GiB | 5 GiB |
cpu-4 | CPU x 4 | 4 vCPUs, 16 GiB memory | At least 12 GiB | 10 GiB |
cpu-16 | CPU x 16 | 16 vCPUs, 64 GiB memory | At least 59 GiB | 40 GiB |
a100-1 | A100 GPU x 1 | 1 A100 GPU, 24 vCPUs, 220 GiB memory | At least 209 GiB | 100 GiB |
h100-1 | H100 GPU x 1 | 1 H100 GPU, 40 vCPUs, 320 GiB memory | At least 307 GiB | 200 GiB |
The compute type affects billing and determines which hardware the task runs on. If a task does not override the compute type, it inherits the workflow-level value.
No other task shares a task's allocated compute, and the task can use all of its vCPUs and GPUs. Some of its memory goes to the containers the platform runs beside the task, so a task can count on its Memory a task can use. Files it writes to its shared memory at /dev/shm are held in that memory too, and a task that uses more than is left fails.
Task storage is the task's private scratch space; Runtime storage describes it and what happens when a task fills it.
Home
Home is each account's landing page, which names the account you are working in, shows its projects' runs as they change, and leads to Swale's resources; see The home page.
Billing
Usage is billed in four dimensions: the compute each task holds, data that leaves the platform, what the account stores, and each run's shared workspace. The account's billing status must be Active before it can start runs, publish task definition versions, or push and pull files. How billing works explains the model.