Skip to content

Commit

Permalink
fix: videos and wording
Browse files Browse the repository at this point in the history
  • Loading branch information
wrussell1999 committed Nov 12, 2024
1 parent 62e2a04 commit 4e2c7a2
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 5 deletions.
10 changes: 10 additions & 0 deletions content/docs/14.best-practices/1.from-dev-to-prod.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,12 @@ You can find more about CI/CD pattern with Kestra [here](../version-control-cicd

#### Git Example

<div class="video-container">
<iframe src="https://www.youtube.com/embed/02bFAu-rpxU?si=bzj_Gs_mxxocdhd2" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe>
</div>

---

We can use the [`git.SyncFlows` task](/plugins/plugin-git/tasks/io.kestra.plugin.git.syncflows) combined with a [Trigger](../04.workflow-components/07.triggers/index.md) to automatically pull Flows from the `main` branch of the Git repository.

This means Kestra will manage the process, reducing the number of systems needed to automate the dev to prod process.
Expand All @@ -75,6 +81,10 @@ While we can be sure that our flows are valid, this will not check for logical e

#### CI/CD Example

<div>
<iframe src="https://www.youtube.com/embed/4MqtD9VtGVs?si=6yuJkPkq29SzKy_r" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe>
</div>

We can use CI/CD to automatically deploy our flows from our Git repository to our production instance of Kestra when they are merged to the `main` branch.

With GitHub, we can use the official [Deploy Action](../version-control-cicd/cicd/01.github-action.md#kestra-actions), which uses the Kestra Server CLI under the hood, to deploy when a Pull Request is merged to `main`.
Expand Down
1 change: 0 additions & 1 deletion content/docs/14.best-practices/3.manage-environments.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ title: Manage Environments
icon: /docs/icons/best-practices.svg
---


Kestra users can manage their "environments" through different levels of granularity. Kestra has three main concepts: instance, tenant, and namespace.

## When to use multiple instances?
Expand Down
9 changes: 6 additions & 3 deletions content/docs/14.best-practices/6.git.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,16 @@ icon: /docs/icons/best-practices.svg
version: ">= 0.17.0"
---

This section describes best practices for Version Control with Git in Kestra.
Best practices for Version Control with Git in Kestra.

By default, **all Kestra flows are automatically versioned**. You don't need to use any additional version control system to track changes to your flows. Kestra automatically creates a new revision of a flow whenever you save it, and you can view the history of changes to a flow, compare changes between revisions, and restore a previous version at any time.
By default, **all Kestra flows are automatically versioned** with [Revisions](../05.concepts/03.revision.md). You don't need to use any additional version control system to track changes to your flows. Kestra automatically creates a new revision of a flow whenever you save it, and you can view the history of changes to a flow, compare changes between revisions, and restore a previous version at any time.

However, if you want to use Git to track changes to your [Flows](../04.workflow-components/01.flow.md) and [Namespace Files](../05.concepts/02.namespace-files.md), you can do so using the built-in Git support in Kestra.

<div class="video-container">
<iframe src="https://www.youtube.com/embed/videoseries?si=wOyAUkgChRUuJxcy&amp;list=PLEK3H8YwZn1p7tyd9RV5-WDxh_ZGpMpA3" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe>
</div>

There are multiple ways to use Git with Kestra:
- The [git.SyncFlows](/plugins/plugin-git/tasks/io.kestra.plugin.git.syncflows) pattern allows you to implement GitOps and use Git as a single source of truth for your flows.
- The [git.SyncNamespaceFiles](/plugins/plugin-git/tasks/io.kestra.plugin.git.syncnamespacefiles) pattern allows you to implement GitOps and use Git as a single source of truth for your namespace files.
Expand All @@ -22,4 +26,3 @@ The image below shows how to choose the right pattern based on your needs:
![git](/docs/developer-guide/git/git.png)

For a detailed comparison of the three patterns, check the [Version Control with Git](../version-control-cicd/04.git.md) page.

2 changes: 1 addition & 1 deletion content/docs/14.best-practices/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ title: Best Practices
icon: /docs/icons/best-practices.svg
---

This section describes best practices for building reliable workflows in Kestra.
Best practices for building reliable workflows in Kestra.

::ChildCard
::
Expand Down
6 changes: 6 additions & 0 deletions content/docs/version-control-cicd/04.git.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ icon: /docs/icons/dev.svg

Setup Version Control with Git to store your flows and namespace files.

<div class="video-container">
<iframe src="https://www.youtube.com/embed/videoseries?si=wOyAUkgChRUuJxcy&amp;list=PLEK3H8YwZn1p7tyd9RV5-WDxh_ZGpMpA3" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe>
</div>

---

Kestra supports version control with Git. You can use one or more Git repositories to store your [Flows](../04.workflow-components/01.flow.md) and [Namespace Files](../05.concepts/02.namespace-files.md), and track changes to them over time via Git commit history.

There are multiple ways to use Git with Kestra:
Expand Down

0 comments on commit 4e2c7a2

Please sign in to comment.