From caaf376e630b98dff4c6eb422e62d601f38e64ca Mon Sep 17 00:00:00 2001 From: Tsiry Sandratraina Date: Mon, 29 Jul 2024 04:07:01 +0000 Subject: [PATCH] update cookbook, add CI integrations examples --- docs/cookbook/build-bun.md | 25 --- docs/cookbook/build-bun.mdx | 152 ++++++++++++++ docs/cookbook/build-containers.md | 35 ---- docs/cookbook/build-containers.mdx | 149 ++++++++++++++ docs/cookbook/build-deno.md | 24 --- docs/cookbook/build-deno.mdx | 169 ++++++++++++++++ docs/cookbook/build-flutter.md | 26 --- docs/cookbook/build-flutter.mdx | 162 +++++++++++++++ docs/cookbook/build-gleam.md | 26 --- docs/cookbook/build-gleam.mdx | 177 ++++++++++++++++ docs/cookbook/build-go.md | 24 --- docs/cookbook/build-go.mdx | 151 ++++++++++++++ docs/cookbook/build-java.md | 24 --- docs/cookbook/build-java.mdx | 151 ++++++++++++++ docs/cookbook/build-nodejs.md | 25 --- docs/cookbook/build-nodejs.mdx | 154 ++++++++++++++ docs/cookbook/build-php.md | 27 --- docs/cookbook/build-php.mdx | 157 +++++++++++++++ docs/cookbook/build-rust.md | 25 --- docs/cookbook/build-rust.mdx | 153 ++++++++++++++ docs/cookbook/build-vm-images-with-packer.md | 25 --- docs/cookbook/build-vm-images-with-packer.mdx | 165 +++++++++++++++ docs/cookbook/build-zig.md | 25 --- docs/cookbook/build-zig.mdx | 154 ++++++++++++++ docs/cookbook/deploy-to-cloudflare.md | 28 --- docs/cookbook/deploy-to-cloudflare.mdx | 152 ++++++++++++++ docs/cookbook/deploy-to-firebase.md | 26 --- docs/cookbook/deploy-to-firebase.mdx | 140 +++++++++++++ docs/cookbook/deploy-to-fly.md | 28 --- docs/cookbook/deploy-to-fly.mdx | 149 ++++++++++++++ docs/cookbook/deploy-to-heroku.md | 26 --- docs/cookbook/deploy-to-heroku.mdx | 150 ++++++++++++++ docs/cookbook/deploy-to-netlify.md | 25 --- docs/cookbook/deploy-to-netlify.mdx | 151 ++++++++++++++ docs/cookbook/deploy-to-railway.md | 25 --- docs/cookbook/deploy-to-railway.mdx | 147 ++++++++++++++ docs/cookbook/deploy-to-shuttle.md | 25 --- docs/cookbook/deploy-to-shuttle.mdx | 147 ++++++++++++++ docs/cookbook/deploy-to-spin.md | 26 --- docs/cookbook/deploy-to-spin.mdx | 159 +++++++++++++++ docs/cookbook/deploy-to-wasmer.md | 26 --- docs/cookbook/deploy-to-wasmer.mdx | 159 +++++++++++++++ docs/cookbook/provision-with-pulumi.md | 29 --- docs/cookbook/provision-with-pulumi.mdx | 166 +++++++++++++++ docs/cookbook/provision-with-terraform.md | 29 --- docs/cookbook/provision-with-terraform.mdx | 190 ++++++++++++++++++ docs/cookbook/upload-to-codecov.md | 27 --- docs/cookbook/upload-to-codecov.mdx | 146 ++++++++++++++ docs/cookbook/upload-to-github-releases.md | 29 --- docs/cookbook/upload-to-github-releases.mdx | 150 ++++++++++++++ docs/cookbook/upload-to-gitlab.md | 27 --- docs/cookbook/upload-to-gitlab.mdx | 161 +++++++++++++++ docs/cookbook/upload-to-r2.md | 28 --- docs/cookbook/upload-to-r2.mdx | 156 ++++++++++++++ docs/cookbook/upload-to-s3.md | 28 --- docs/cookbook/upload-to-s3.mdx | 156 ++++++++++++++ src/css/custom.css | 4 + src/theme/prism-include-languages.js | 23 +++ 58 files changed, 4400 insertions(+), 743 deletions(-) delete mode 100644 docs/cookbook/build-bun.md create mode 100644 docs/cookbook/build-bun.mdx delete mode 100644 docs/cookbook/build-containers.md create mode 100644 docs/cookbook/build-containers.mdx delete mode 100644 docs/cookbook/build-deno.md create mode 100644 docs/cookbook/build-deno.mdx delete mode 100644 docs/cookbook/build-flutter.md create mode 100644 docs/cookbook/build-flutter.mdx delete mode 100644 docs/cookbook/build-gleam.md create mode 100644 docs/cookbook/build-gleam.mdx delete mode 100644 docs/cookbook/build-go.md create mode 100644 docs/cookbook/build-go.mdx delete mode 100644 docs/cookbook/build-java.md create mode 100644 docs/cookbook/build-java.mdx delete mode 100644 docs/cookbook/build-nodejs.md create mode 100644 docs/cookbook/build-nodejs.mdx delete mode 100644 docs/cookbook/build-php.md create mode 100644 docs/cookbook/build-php.mdx delete mode 100644 docs/cookbook/build-rust.md create mode 100644 docs/cookbook/build-rust.mdx delete mode 100644 docs/cookbook/build-vm-images-with-packer.md create mode 100644 docs/cookbook/build-vm-images-with-packer.mdx delete mode 100644 docs/cookbook/build-zig.md create mode 100644 docs/cookbook/build-zig.mdx delete mode 100644 docs/cookbook/deploy-to-cloudflare.md create mode 100644 docs/cookbook/deploy-to-cloudflare.mdx delete mode 100644 docs/cookbook/deploy-to-firebase.md create mode 100644 docs/cookbook/deploy-to-firebase.mdx delete mode 100644 docs/cookbook/deploy-to-fly.md create mode 100644 docs/cookbook/deploy-to-fly.mdx delete mode 100644 docs/cookbook/deploy-to-heroku.md create mode 100644 docs/cookbook/deploy-to-heroku.mdx delete mode 100644 docs/cookbook/deploy-to-netlify.md create mode 100644 docs/cookbook/deploy-to-netlify.mdx delete mode 100644 docs/cookbook/deploy-to-railway.md create mode 100644 docs/cookbook/deploy-to-railway.mdx delete mode 100644 docs/cookbook/deploy-to-shuttle.md create mode 100644 docs/cookbook/deploy-to-shuttle.mdx delete mode 100644 docs/cookbook/deploy-to-spin.md create mode 100644 docs/cookbook/deploy-to-spin.mdx delete mode 100644 docs/cookbook/deploy-to-wasmer.md create mode 100644 docs/cookbook/deploy-to-wasmer.mdx delete mode 100644 docs/cookbook/provision-with-pulumi.md create mode 100644 docs/cookbook/provision-with-pulumi.mdx delete mode 100644 docs/cookbook/provision-with-terraform.md create mode 100644 docs/cookbook/provision-with-terraform.mdx delete mode 100644 docs/cookbook/upload-to-codecov.md create mode 100644 docs/cookbook/upload-to-codecov.mdx delete mode 100644 docs/cookbook/upload-to-github-releases.md create mode 100644 docs/cookbook/upload-to-github-releases.mdx delete mode 100644 docs/cookbook/upload-to-gitlab.md create mode 100644 docs/cookbook/upload-to-gitlab.mdx delete mode 100644 docs/cookbook/upload-to-r2.md create mode 100644 docs/cookbook/upload-to-r2.mdx delete mode 100644 docs/cookbook/upload-to-s3.md create mode 100644 docs/cookbook/upload-to-s3.mdx create mode 100644 src/theme/prism-include-languages.js diff --git a/docs/cookbook/build-bun.md b/docs/cookbook/build-bun.md deleted file mode 100644 index 151a60e..0000000 --- a/docs/cookbook/build-bun.md +++ /dev/null @@ -1,25 +0,0 @@ ---- -sidebar_position: 1 ---- - -# Build and test Bun applications - -This guide will show you how to build and test Bun applications with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Bun`. In addition: - -- Have your `Bun` project handy, including `package.json` and `test` files. - -## Using the Bun Plugin - -You can use FluentCI to build Bun applications using [bun plugin](https://github.com/fluent-ci-templates/bun-pipeline), no need to install Bun on your machine, FluentCI will handle everything for you. - -The following commands can be used to build and test Bun applications: - -```bash -fluentci run --wasm bun test -fluentci run --wasm bun build -``` - diff --git a/docs/cookbook/build-bun.mdx b/docs/cookbook/build-bun.mdx new file mode 100644 index 0000000..749c977 --- /dev/null +++ b/docs/cookbook/build-bun.mdx @@ -0,0 +1,152 @@ +--- +sidebar_position: 1 +--- + +# Build and test Bun applications + +This guide will show you how to build and test Bun applications with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Bun`. In addition: + +- Have your `Bun` project handy, including `package.json` and `test` files. + +## Using the Bun Plugin + +You can use FluentCI to build Bun applications using [bun plugin](https://github.com/fluent-ci-templates/bun-pipeline), no need to install Bun on your machine, FluentCI will handle everything for you. + +The following commands can be used to build and test Bun applications: + +```bash +fluentci run --wasm bun test +fluentci run --wasm bun build +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to build and test Bun applications: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: tests + run: fluentci run --wasm bun test + - name: build + run: fluentci run --wasm bun build + `} + + + + + {` +.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +tests: + extends: .fluentci + script: - fluentci run --wasm bun test +build: + extends: .fluentci + script: - fluentci run --wasm bun build +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm bun test + name: tests + - run: fluentci run --wasm bun build + name: build + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job +`} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm bun test + displayName: tests + - script: fluentci run --wasm bun build + displayName: build +`} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm bun test + - fluentci run --wasm bun build + post_build: + commands: + - echo Build completed on \`date\``} + + + diff --git a/docs/cookbook/build-containers.md b/docs/cookbook/build-containers.md deleted file mode 100644 index b3b4ad5..0000000 --- a/docs/cookbook/build-containers.md +++ /dev/null @@ -1,35 +0,0 @@ ---- -sidebar_position: 2 ---- - -# Build Container Images - -This page explains how to build container images for your applications using FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Docker`. In addition: - -- Have Docker installed on your machine. -- Have your application source code along with `Dockerfile` handy. - -## Using the Buildx Plugin - -You can use FluentCI to build container images using the [buildx plugin](https://github.com/tsirysndr/daggerverse/tree/main/buildx), no need to install buildx on your machine, FluentCI will handle everything for you. - -The following command can be used to build container images: - -```bash -fluentci run --wasm buildx build --platform linux/amd64,linux/arm64 -t demo:latest . -``` - -## Using the Nixpacks Plugin - -You can use FluentCI to build container images using the [nixpacks plugin](https://github.com/tsirysndr/daggerverse/tree/main/nixpacks), no need to install nixpacks on your machine, FluentCI will handle everything for you. - -The following command can be used to plan and build container image: - -```bash -fluentci run --wasm nixpacks nixpacks plan . --format json -fluentci run --wasm nixpacks nixpacks build . --name myapp -``` diff --git a/docs/cookbook/build-containers.mdx b/docs/cookbook/build-containers.mdx new file mode 100644 index 0000000..b5f088f --- /dev/null +++ b/docs/cookbook/build-containers.mdx @@ -0,0 +1,149 @@ +--- +sidebar_position: 2 +--- + +# Build Container Images + +This page explains how to build container images for your applications using FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Docker`. In addition: + +- Have Docker installed on your machine. +- Have your application source code along with `Dockerfile` handy. + +## Using the Buildx Plugin + +You can use FluentCI to build container images using the [buildx plugin](https://github.com/tsirysndr/daggerverse/tree/main/buildx), no need to install buildx on your machine, FluentCI will handle everything for you. + +The following command can be used to build container images: + +```bash +fluentci run --wasm buildx build --platform linux/amd64,linux/arm64 -t demo:latest . +``` + +## Using the Nixpacks Plugin + +You can use FluentCI to build container images using the [nixpacks plugin](https://github.com/tsirysndr/daggerverse/tree/main/nixpacks), no need to install nixpacks on your machine, FluentCI will handle everything for you. + +The following command can be used to plan and build container image: + +```bash +fluentci run --wasm nixpacks nixpacks plan . --format json +fluentci run --wasm nixpacks nixpacks build . --name myapp +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to build container images: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: build + run: fluentci run --wasm buildx build`} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +build: + extends: .fluentci +script: - fluentci run --wasm buildx build +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm buildx build + name: build + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job`} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm buildx build + displayName: build`} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm buildx build + post_build: + commands: + - echo Build completed on \`date\``} + + + diff --git a/docs/cookbook/build-deno.md b/docs/cookbook/build-deno.md deleted file mode 100644 index 836c318..0000000 --- a/docs/cookbook/build-deno.md +++ /dev/null @@ -1,24 +0,0 @@ ---- -sidebar_position: 3 ---- - -# Build and test Deno applications - -This page explains how to build and test Deno applications with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Deno`. In addition: - -- Have your `Deno` project handy, including `deno.json` and `test` files. - -## Using the Deno Plugin - -You can use FluentCI to build Deno applications using [deno plugin](https://github.com/fluent-ci-templates/deno-pipeline), no need to install Deno on your machine, FluentCI will handle everything for you. - -The following commands can be used to build and test Deno applications: - -```bash -fluentci run --wasm deno test -fluentci run --wasm deno compile -A --output myapp --target x86_64-unknown-linux-gnu main.ts # suppose main.ts is your entry file -``` diff --git a/docs/cookbook/build-deno.mdx b/docs/cookbook/build-deno.mdx new file mode 100644 index 0000000..cb4e3d1 --- /dev/null +++ b/docs/cookbook/build-deno.mdx @@ -0,0 +1,169 @@ +--- +sidebar_position: 3 +--- + +# Build and test Deno applications + +This page explains how to build and test Deno applications with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Deno`. In addition: + +- Have your `Deno` project handy, including `deno.json` and `test` files. + +## Using the Deno Plugin + +You can use FluentCI to build Deno applications using [deno plugin](https://github.com/fluent-ci-templates/deno-pipeline), no need to install Deno on your machine, FluentCI will handle everything for you. + +The following commands can be used to build and test Deno applications: + +```bash +fluentci run --wasm deno test +fluentci run --wasm deno compile -A --output myapp --target x86_64-unknown-linux-gnu main.ts # suppose main.ts is your entry file +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to build and test Deno applications: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: fmt + run: fluentci run --wasm deno fmt + - name: lint + run: fluentci run --wasm deno lint + - name: tests + run: fluentci run --wasm deno test + - name: compile + run: fluentci run --wasm deno compile -A --output myapp --target + x86_64-unknown-linux-gnu main.ts`} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +fmt: + extends: .fluentci + script: - fluentci run --wasm deno fmt +lint: + extends: .fluentci + script: - fluentci run --wasm deno lint +tests: + extends: .fluentci + script: - fluentci run --wasm deno test +compile: + extends: .fluentci + script: - fluentci run --wasm deno compile -A --output myapp --target x86_64-unknown-linux-gnu main.ts +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm deno fmt + name: fmt + - run: fluentci run --wasm deno lint + name: lint + - run: fluentci run --wasm deno test + name: tests + - run: fluentci run --wasm deno compile -A --output myapp --target x86_64-unknown-linux-gnu main.ts + name: compile + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job`} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm deno fmt + displayName: fmt + - script: fluentci run --wasm deno lint + displayName: lint + - script: fluentci run --wasm deno test + displayName: tests + - script: fluentci run --wasm deno compile -A --output myapp --target x86_64-unknown-linux-gnu main.ts + displayName: compile`} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm deno fmt + - fluentci run --wasm deno lint + - fluentci run --wasm deno test + - fluentci run --wasm deno compile -A --output myapp --target + x86_64-unknown-linux-gnu main.ts + post_build: + commands: + - echo Build completed on \`date\``} + + + diff --git a/docs/cookbook/build-flutter.md b/docs/cookbook/build-flutter.md deleted file mode 100644 index ceffc1c..0000000 --- a/docs/cookbook/build-flutter.md +++ /dev/null @@ -1,26 +0,0 @@ ---- -sidebar_position: 4 ---- - -# Build and test Flutter applications - -This guide will help you build and test Flutter applications with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Flutter`. In addition: - -- Be familiar with creating Flutter-based applications. -- Have your Flutter project ready. - -## Using the Flutter Plugin - -You can use FluentCI to build and test Flutter applications using the [flutter plugin](https://github.com/fluent-ci-templates/flutter-pipeline), no need to install Flutter on your machine, FluentCI will handle everything for you. - -The following commands can be used to build and test Flutter applications: - -```bash -fluentci run --wasm flutter code_quality -fluentci run --wasm flutter test -fluentci run --wasm flutter build -``` diff --git a/docs/cookbook/build-flutter.mdx b/docs/cookbook/build-flutter.mdx new file mode 100644 index 0000000..387957c --- /dev/null +++ b/docs/cookbook/build-flutter.mdx @@ -0,0 +1,162 @@ +--- +sidebar_position: 4 +--- + +# Build and test Flutter applications + +This guide will help you build and test Flutter applications with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Flutter`. In addition: + +- Be familiar with creating Flutter-based applications. +- Have your Flutter project ready. + +## Using the Flutter Plugin + +You can use FluentCI to build and test Flutter applications using the [flutter plugin](https://github.com/fluent-ci-templates/flutter-pipeline), no need to install Flutter on your machine, FluentCI will handle everything for you. + +The following commands can be used to build and test Flutter applications: + +```bash +fluentci run --wasm flutter code_quality +fluentci run --wasm flutter test +fluentci run --wasm flutter build +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to build and test Flutter applications: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: code_quality + run: fluentci run --wasm flutter code_quality + - name: test + run: fluentci run --wasm flutter test + - name: build + run: fluentci run --wasm flutter build`} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +code_quality: + extends: .fluentci + script: - fluentci run --wasm flutter code_quality +test: + extends: .fluentci + script: - fluentci run --wasm flutter test +build: + extends: .fluentci + script: - fluentci run --wasm flutter build +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm flutter code_quality + name: code_quality + - run: fluentci run --wasm flutter test + name: test + - run: fluentci run --wasm flutter build + name: build + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job +`} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm flutter code_quality + displayName: code_quality + - script: fluentci run --wasm flutter test + displayName: test + - script: fluentci run --wasm flutter build + displayName: build +`} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm flutter code_quality + - fluentci run --wasm flutter test + - fluentci run --wasm flutter build + post_build: + commands: + - echo Build completed on \`date\``} + + + diff --git a/docs/cookbook/build-gleam.md b/docs/cookbook/build-gleam.md deleted file mode 100644 index e99acb6..0000000 --- a/docs/cookbook/build-gleam.md +++ /dev/null @@ -1,26 +0,0 @@ ---- -sidebar_position: 5 ---- - -# Build and test Gleam applications - -This page explains how to build and test Gleam applications with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Gleam`. In addition: - -- Be familiar with creating Gleam-based applications. -- Have your Gleam project ready. - -## Using the Gleam Plugin - -You can use FluentCI to build and test Gleam applications using the [gleam plugin](https://github.com/fluent-ci-templates/gleam-pipeline), no need to install Gleam on your machine, FluentCI will handle everything for you. - -The following commands can be used to build and test Gleam applications: - -```bash -fluentci run --wasm gleam test -fluentci run --wasm gleam build -``` - diff --git a/docs/cookbook/build-gleam.mdx b/docs/cookbook/build-gleam.mdx new file mode 100644 index 0000000..7ce545c --- /dev/null +++ b/docs/cookbook/build-gleam.mdx @@ -0,0 +1,177 @@ +--- +sidebar_position: 5 +--- + +# Build and test Gleam applications + +This page explains how to build and test Gleam applications with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Gleam`. In addition: + +- Be familiar with creating Gleam-based applications. +- Have your Gleam project ready. + +## Using the Gleam Plugin + +You can use FluentCI to build and test Gleam applications using the [gleam plugin](https://github.com/fluent-ci-templates/gleam-pipeline), no need to install Gleam on your machine, FluentCI will handle everything for you. + +The following commands can be used to build and test Gleam applications: + +```bash +fluentci run --wasm gleam test +fluentci run --wasm gleam build +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to build and test Gleam applications: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: check + run: fluentci run --wasm gleam check + - name: format + run: fluentci run --wasm gleam format + - name: test + run: fluentci run --wasm gleam test + - name: build + run: fluentci run --wasm gleam build +`} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +check: + extends: .fluentci + script: + - fluentci run --wasm gleam check +format: + extends: .fluentci + script: + - fluentci run --wasm gleam format +test: + extends: .fluentci + script: + - fluentci run --wasm gleam test +build: + extends: .fluentci + script: + - fluentci run --wasm gleam build +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm gleam check + name: check + - run: fluentci run --wasm gleam format + name: format + - run: fluentci run --wasm gleam test + name: test + - run: fluentci run --wasm gleam build + name: build + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job +`} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm gleam check + displayName: check + - script: fluentci run --wasm gleam format + displayName: format + - script: fluentci run --wasm gleam test + displayName: test + - script: fluentci run --wasm gleam build + displayName: build + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm gleam check + - fluentci run --wasm gleam format + - fluentci run --wasm gleam test + - fluentci run --wasm gleam build + post_build: + commands: + - echo Build completed on \`date\` +`} + + + diff --git a/docs/cookbook/build-go.md b/docs/cookbook/build-go.md deleted file mode 100644 index e0f23bc..0000000 --- a/docs/cookbook/build-go.md +++ /dev/null @@ -1,24 +0,0 @@ ---- -sidebar_position: 6 ---- - -# Build and test Go applications - -This page explains how to FluentCI to build and test Go applications. - -## Before you begin - -The instructions on this page assume that you are familiar with `Go`. In addition: - -- Have your Go project handy. - -## Using the Go Plugin - -You can use FluentCI to build and test Go applications using the [go plugin](https://github.com/fluent-ci-templates/go-pipeline), no need to install Go on your machine, FluentCI will handle everything for you. - -The following commands can be used to build and test Go applications: - -```bash -fluentci run --wasm go test -fluentci run --wasm go build -``` diff --git a/docs/cookbook/build-go.mdx b/docs/cookbook/build-go.mdx new file mode 100644 index 0000000..4d530bc --- /dev/null +++ b/docs/cookbook/build-go.mdx @@ -0,0 +1,151 @@ +--- +sidebar_position: 6 +--- + +# Build and test Go applications + +This page explains how to FluentCI to build and test Go applications. + +## Before you begin + +The instructions on this page assume that you are familiar with `Go`. In addition: + +- Have your Go project handy. + +## Using the Go Plugin + +You can use FluentCI to build and test Go applications using the [go plugin](https://github.com/fluent-ci-templates/go-pipeline), no need to install Go on your machine, FluentCI will handle everything for you. + +The following commands can be used to build and test Go applications: + +```bash +fluentci run --wasm go test +fluentci run --wasm go build +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to build and test Go applications: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: test + run: fluentci run --wasm go test + - name: build + run: fluentci run --wasm go build + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +test: + extends: .fluentci + script: - fluentci run --wasm go test +build: + extends: .fluentci + script: - fluentci run --wasm go build +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm go test + name: test + - run: fluentci run --wasm go build + name: build + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job +`} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm go test + displayName: test + - script: fluentci run --wasm go build + displayName: build +`} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm go test + - fluentci run --wasm go build + post_build: + commands: + - echo Build completed on \`date\``} + + + diff --git a/docs/cookbook/build-java.md b/docs/cookbook/build-java.md deleted file mode 100644 index 27a79e0..0000000 --- a/docs/cookbook/build-java.md +++ /dev/null @@ -1,24 +0,0 @@ ---- -sidebar_position: 7 ---- - -# Build and test Java applications - -This guide will help you build and test Java applications with FluentCI. - -## Before you begin - -- Be familiar with creating Java-based applications. -- Be familiar with [Maven](https://maven.apache.org/maven-features.html) -- Have your Java project ready. - -## Using the Maven Plugin - -You can use FluentCI to build Java applications using [maven plugin](https://github.com/fluentci-io/maven-plugin), no need to install Maven or JDK on your machine, FluentCI will handle everything for you. - -The following commands can be used to build and test Java applications: - -```bash -fluentci run --wasm maven test -fluentci run --wasm maven package -Dmaven.test.skip=true -``` diff --git a/docs/cookbook/build-java.mdx b/docs/cookbook/build-java.mdx new file mode 100644 index 0000000..ee36184 --- /dev/null +++ b/docs/cookbook/build-java.mdx @@ -0,0 +1,151 @@ +--- +sidebar_position: 7 +--- + +# Build and test Java applications + +This guide will help you build and test Java applications with FluentCI. + +## Before you begin + +- Be familiar with creating Java-based applications. +- Be familiar with [Maven](https://maven.apache.org/maven-features.html) +- Have your Java project ready. + +## Using the Maven Plugin + +You can use FluentCI to build Java applications using [maven plugin](https://github.com/fluentci-io/maven-plugin), no need to install Maven or JDK on your machine, FluentCI will handle everything for you. + +The following commands can be used to build and test Java applications: + +```bash +fluentci run --wasm maven test +fluentci run --wasm maven package -Dmaven.test.skip=true +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to build and test Java applications: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: test + run: fluentci run --wasm maven test + - name: package + run: fluentci run --wasm maven package -Dmaven.test.skip=true + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +test: + extends: .fluentci + script: + - fluentci run --wasm maven test +package: + extends: .fluentci + script: + - fluentci run --wasm maven package -Dmaven.test.skip=true +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm maven test + name: test + - run: fluentci run --wasm maven package -Dmaven.test.skip=true + name: package + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job`} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm maven test + displayName: test + - script: fluentci run --wasm maven package -Dmaven.test.skip=true + displayName: package`} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm maven test + - fluentci run --wasm maven package -Dmaven.test.skip=true + post_build: + commands: + - echo Build completed on \`date\``} + + + diff --git a/docs/cookbook/build-nodejs.md b/docs/cookbook/build-nodejs.md deleted file mode 100644 index 4f996ec..0000000 --- a/docs/cookbook/build-nodejs.md +++ /dev/null @@ -1,25 +0,0 @@ ---- -sidebar_position: 8 ---- - -# Build and test Node.js applications - -This page explains how to build and test Nodejs applications with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Nodejs`. In addition: - -- Have your `Node.js` project handy, including `package.json` and `test.js` files. -- Make sure your `package.json` file includes a `build` script and a `test` script. - -## Using the Node.js Plugin - -You can use FluentCI to build and test Node.js applications using the [node.js plugin](https://github.com/fluent-ci-templates/nodejs-pipeline), no need to install Node.js on your machine, FluentCI will handle everything for you. - -The following commands can be used to build and test Node.js applications: - -```bash -fluentci run --wasm nodejs test -fluentci run --wasm nodejs build -``` diff --git a/docs/cookbook/build-nodejs.mdx b/docs/cookbook/build-nodejs.mdx new file mode 100644 index 0000000..aefe1af --- /dev/null +++ b/docs/cookbook/build-nodejs.mdx @@ -0,0 +1,154 @@ +--- +sidebar_position: 8 +--- + +# Build and test Node.js applications + +This page explains how to build and test Nodejs applications with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Nodejs`. In addition: + +- Have your `Node.js` project handy, including `package.json` and `test.js` files. +- Make sure your `package.json` file includes a `build` script and a `test` script. + +## Using the Node.js Plugin + +You can use FluentCI to build and test Node.js applications using the [node.js plugin](https://github.com/fluent-ci-templates/nodejs-pipeline), no need to install Node.js on your machine, FluentCI will handle everything for you. + +The following commands can be used to build and test Node.js applications: + +```bash +fluentci run --wasm nodejs test +fluentci run --wasm nodejs build +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to build and test Node.js applications: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: test + run: fluentci run --wasm nodejs test + - name: build + run: fluentci run --wasm nodejs build + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +test: + extends: .fluentci + script: + - fluentci run --wasm nodejs test +build: + extends: .fluentci + script: + - fluentci run --wasm nodejs build +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm nodejs test + name: test + - run: fluentci run --wasm nodejs build + name: build + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm nodejs test + displayName: test + - script: fluentci run --wasm nodejs build + displayName: build +`} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm nodejs test + - fluentci run --wasm nodejs build + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/build-php.md b/docs/cookbook/build-php.md deleted file mode 100644 index d46bca0..0000000 --- a/docs/cookbook/build-php.md +++ /dev/null @@ -1,27 +0,0 @@ ---- -sidebar_position: 9 ---- - -# Test PHP applications - -This guide will help you to test PHP applications with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `PHP`. In addition: - -- Be familiar with creating PHP-based applications. -- Have your PHP project ready. -- Have your `composer.json` and `phpunit.xml` files ready. -- Have your tests written in the `tests` directory. - -## Using the PHP Plugin - -You can use FluentCI to test PHP applications using the [php plugin](https://github.com/fluent-ci-templates/php-pipeline), no need to install PHP on your machine, FluentCI will handle everything for you. - -The following commands can be used to test PHP applications: - -```bash -fluentci run --wasm php compose_install -fluentci run --wasm php test -``` diff --git a/docs/cookbook/build-php.mdx b/docs/cookbook/build-php.mdx new file mode 100644 index 0000000..7e9d0d8 --- /dev/null +++ b/docs/cookbook/build-php.mdx @@ -0,0 +1,157 @@ +--- +sidebar_position: 9 +--- + +# Test PHP applications + +This guide will help you to test PHP applications with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `PHP`. In addition: + +- Be familiar with creating PHP-based applications. +- Have your PHP project ready. +- Have your `composer.json` and `phpunit.xml` files ready. +- Have your tests written in the `tests` directory. + +## Using the PHP Plugin + +You can use FluentCI to test PHP applications using the [php plugin](https://github.com/fluent-ci-templates/php-pipeline), no need to install PHP on your machine, FluentCI will handle everything for you. + +The following commands can be used to test PHP applications: + +```bash +fluentci run --wasm php compose_install +fluentci run --wasm php test +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to test PHP applications: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: composer install + run: fluentci run --wasm php composer_install + - name: test + run: fluentci run --wasm php test + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +composer install: + extends: .fluentci + script: + - fluentci run --wasm php composer_install +test: + extends: .fluentci + script: + - fluentci run --wasm php test +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm php composer_install + name: composer install + - run: fluentci run --wasm php test + name: test + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm php composer_install + displayName: composer install + - script: fluentci run --wasm php test + displayName: test + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm php composer_install + - fluentci run --wasm php test + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/build-rust.md b/docs/cookbook/build-rust.md deleted file mode 100644 index 01cbea6..0000000 --- a/docs/cookbook/build-rust.md +++ /dev/null @@ -1,25 +0,0 @@ ---- -sidebar_position: 10 ---- - -# Build and test Rust applications - -This page explains how to build and test Rust applications with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Rust`. In addition: - -- Be familiar with creating Rust-based applications. -- Have your `Rust` project ready, including `test` files. - -## Using the Rust Plugin - -You can use FluentCI to build and test Rust applications using the [rust plugin](https://github.com/fluent-ci-templates/rust-pipeline), no need to install Rust on your machine, FluentCI will handle everything for you. - -The following commands can be used to build and test Rust applications: - -```bash -fluentci run --wasm rust test -fluentci run --wasm rust build -``` diff --git a/docs/cookbook/build-rust.mdx b/docs/cookbook/build-rust.mdx new file mode 100644 index 0000000..88eb7cb --- /dev/null +++ b/docs/cookbook/build-rust.mdx @@ -0,0 +1,153 @@ +--- +sidebar_position: 10 +--- + +# Build and test Rust applications + +This page explains how to build and test Rust applications with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Rust`. In addition: + +- Be familiar with creating Rust-based applications. +- Have your `Rust` project ready, including `test` files. + +## Using the Rust Plugin + +You can use FluentCI to build and test Rust applications using the [rust plugin](https://github.com/fluent-ci-templates/rust-pipeline), no need to install Rust on your machine, FluentCI will handle everything for you. + +The following commands can be used to build and test Rust applications: + +```bash +fluentci run --wasm rust test +fluentci run --wasm rust build +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to build and test Rust applications: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: test + run: fluentci run --wasm rust test + - name: build + run: fluentci run --wasm rust build + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +test: + extends: .fluentci + script: + - fluentci run --wasm rust test +build: + extends: .fluentci + script: + - fluentci run --wasm rust build +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm rust test + name: test + - run: fluentci run --wasm rust build + name: build + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm rust test + displayName: test + - script: fluentci run --wasm rust build + displayName: build`} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm rust test + - fluentci run --wasm rust build + post_build: + commands: + - echo Build completed on \`date\``} + + + diff --git a/docs/cookbook/build-vm-images-with-packer.md b/docs/cookbook/build-vm-images-with-packer.md deleted file mode 100644 index 56955b1..0000000 --- a/docs/cookbook/build-vm-images-with-packer.md +++ /dev/null @@ -1,25 +0,0 @@ ---- -sidebar_position: 11 ---- - -# Build VM images with Packer - -[Packer](https://www.packer.io) is an open source tool for creating identical Virtual Machine (VM) images for multiple platforms from a single source configuration. This page explains how to use Packer and FluentCI to create a VM image. - -## Before you begin - -The instructions on this page assume that you are familiar with `Packer`. In addition: - -- Have your source code including the [Packer template](https://www.packer.io/docs/templates) handy. - -## Using the Packer Plugin - -You can use FluentCI to build VM images using the [packer plugin](https://github.com/fluentci-io/packer-plugin), no need to install Packer on your machine, FluentCI will handle everything for you. - -The following command can be used to build VM image with Packer: - -```bash -fluenci run --wasm packer fmt -fluenci run --wasm packer validate -fluenci run --wasm packer build -``` diff --git a/docs/cookbook/build-vm-images-with-packer.mdx b/docs/cookbook/build-vm-images-with-packer.mdx new file mode 100644 index 0000000..355e353 --- /dev/null +++ b/docs/cookbook/build-vm-images-with-packer.mdx @@ -0,0 +1,165 @@ +--- +sidebar_position: 11 +--- + +# Build VM images with Packer + +[Packer](https://www.packer.io) is an open source tool for creating identical Virtual Machine (VM) images for multiple platforms from a single source configuration. This page explains how to use Packer and FluentCI to create a VM image. + +## Before you begin + +The instructions on this page assume that you are familiar with `Packer`. In addition: + +- Have your source code including the [Packer template](https://www.packer.io/docs/templates) handy. + +## Using the Packer Plugin + +You can use FluentCI to build VM images using the [packer plugin](https://github.com/fluentci-io/packer-plugin), no need to install Packer on your machine, FluentCI will handle everything for you. + +The following command can be used to build VM image with Packer: + +```bash +fluenci run --wasm packer fmt +fluenci run --wasm packer validate +fluenci run --wasm packer build +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to build VM images with Packer: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: fmt + run: fluentci run --wasm packer fmt + - name: validate + run: fluentci run --wasm packer validate + - name: build + run: fluentci run --wasm packer build + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +fmt: + extends: .fluentci + script: + - fluentci run --wasm packer fmt +validate: + extends: .fluentci + script: + - fluentci run --wasm packer validate +build: + extends: .fluentci + script: + - fluentci run --wasm packer build +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm packer fmt + name: fmt + - run: fluentci run --wasm packer validate + name: validate + - run: fluentci run --wasm packer build + name: build + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job`} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm packer fmt + displayName: fmt + - script: fluentci run --wasm packer validate + displayName: validate + - script: fluentci run --wasm packer build + displayName: build + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm packer fmt + - fluentci run --wasm packer validate + - fluentci run --wasm packer build + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/build-zig.md b/docs/cookbook/build-zig.md deleted file mode 100644 index 800c957..0000000 --- a/docs/cookbook/build-zig.md +++ /dev/null @@ -1,25 +0,0 @@ ---- -sidebar_position: 12 ---- - -# Build and test Zig applications - -This guide will help you build and test Zig applications with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Zig`. In addition: - -- Be familiar with creating Zig-based applications. -- Have your Zig project ready, including `test` files. - -## Using the Zig Plugin - -You can use FluentCI to build and test Zig applications using the [zig plugin](https://github.com/fluent-ci-templates/zig-pipeline), no need to install Zig on your machine, FluentCI will handle everything for you. - -The following commands can be used to build and test Zig applications: - -```bash -fluentci run --wasm zig test -fluentci run --wasm zig build -``` diff --git a/docs/cookbook/build-zig.mdx b/docs/cookbook/build-zig.mdx new file mode 100644 index 0000000..d0c9d76 --- /dev/null +++ b/docs/cookbook/build-zig.mdx @@ -0,0 +1,154 @@ +--- +sidebar_position: 12 +--- + +# Build and test Zig applications + +This guide will help you build and test Zig applications with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Zig`. In addition: + +- Be familiar with creating Zig-based applications. +- Have your Zig project ready, including `test` files. + +## Using the Zig Plugin + +You can use FluentCI to build and test Zig applications using the [zig plugin](https://github.com/fluent-ci-templates/zig-pipeline), no need to install Zig on your machine, FluentCI will handle everything for you. + +The following commands can be used to build and test Zig applications: + +```bash +fluentci run --wasm zig test +fluentci run --wasm zig build +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to build and test Zig applications: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: test + run: fluentci run --wasm zig test + - name: build + run: fluentci run --wasm zig build + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +test: + extends: .fluentci + script: + - fluentci run --wasm zig test +build: + extends: .fluentci + script: + - fluentci run --wasm zig build +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm zig test + name: test + - run: fluentci run --wasm zig build + name: build + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm zig test + displayName: test + - script: fluentci run --wasm zig build + displayName: build + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm zig test + - fluentci run --wasm zig build + post_build: + commands: + - echo Build completed on \`date\``} + + + diff --git a/docs/cookbook/deploy-to-cloudflare.md b/docs/cookbook/deploy-to-cloudflare.md deleted file mode 100644 index 5bcc809..0000000 --- a/docs/cookbook/deploy-to-cloudflare.md +++ /dev/null @@ -1,28 +0,0 @@ ---- -sidebar_position: 13 ---- - -# Deploy to Cloudflare - -This guide will show you how to deploy a React application to Cloudflare Pages and a Cloudflare Worker using FluentCI. - -## Before you begin - -- Have your React project ready. -- Have a Cloudflare account. -- Have a Cloudflare Pages project set up. -- Have a Cloudflare Worker set up. - -## Using the Cloudflare Plugin - -You can use FluentCI to deploy your React application to Cloudflare Pages and a Cloudflare Worker using the [cloudflare plugin](https://github.com/fluent-ci-templates/cloudflare-pipeline), no need to install Cloudflare Wrangler CLI or Node.js on your machine, FluentCI will handle everything for you. - -The following commands can be used to deploy your React application to Cloudflare Pages: - -```bash - fluentci run --wasm bun run build - fluentci run --wasm cloudflare pages_deploy dist --project-name $PROJECT_NAME - # to deploy a Cloudflare Worker, set CLOUDFLARE_API_TOKEN and CLOUDFLARE_ACCOUNT_ID - # in your environment variables and run: - fluentci run --wasm cloudflare deploy -``` diff --git a/docs/cookbook/deploy-to-cloudflare.mdx b/docs/cookbook/deploy-to-cloudflare.mdx new file mode 100644 index 0000000..ffbe58b --- /dev/null +++ b/docs/cookbook/deploy-to-cloudflare.mdx @@ -0,0 +1,152 @@ +--- +sidebar_position: 13 +--- + +# Deploy to Cloudflare + +This guide will show you how to deploy a React application to Cloudflare Pages and a Cloudflare Worker using FluentCI. + +## Before you begin + +- Have your React project ready. +- Have a Cloudflare account. +- Have a Cloudflare Pages project set up. +- Have a Cloudflare Worker set up. + +## Using the Cloudflare Plugin + +You can use FluentCI to deploy your React application to Cloudflare Pages and a Cloudflare Worker using the [cloudflare plugin](https://github.com/fluent-ci-templates/cloudflare-pipeline), no need to install Cloudflare Wrangler CLI or Node.js on your machine, FluentCI will handle everything for you. + +The following commands can be used to deploy your React application to Cloudflare Pages: + +```bash + fluentci run --wasm bun run build + fluentci run --wasm cloudflare pages_deploy dist --project-name $PROJECT_NAME + # to deploy a Cloudflare Worker, set CLOUDFLARE_API_TOKEN and CLOUDFLARE_ACCOUNT_ID + # in your environment variables and run: + fluentci run --wasm cloudflare deploy +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to deploy your applications to Cloudflare Pages and a Cloudflare Worker: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: deploy + run: fluentci run --wasm cloudflare deploy + env: + CLOUDFLARE_API_TOKEN: \${{ secrets.CLOUDFLARE_API_TOKEN }} + CLOUDFLARE_ACCOUNT_ID: \${{ secrets.CLOUDFLARE_ACCOUNT_ID }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + CLOUDFLARE_API_TOKEN: $CLOUDFLARE_API_TOKEN + CLOUDFLARE_ACCOUNT_ID: $CLOUDFLARE_ACCOUNT_ID +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +deploy: + extends: .fluentci + script: + - fluentci run --wasm cloudflare deploy +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm cloudflare deploy + name: deploy + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm cloudflare deploy + displayName: deploy + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm cloudflare deploy + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/deploy-to-firebase.md b/docs/cookbook/deploy-to-firebase.md deleted file mode 100644 index 512d3c0..0000000 --- a/docs/cookbook/deploy-to-firebase.md +++ /dev/null @@ -1,26 +0,0 @@ ---- -sidebar_position: 14 ---- - -# Deploy to Firebase - -This page explains how to deploy applications to Firebase using FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Firebase`. In addition: - -- Have your Firebase project ready. -- If you don't already have a project to deploy to Firebase, you can create a default project by [installing and initializing Firebase](https://firebase.google.com/docs/hosting/quickstart#initialize). - -## Using the Firebase Plugin - -You can use FluentCI to deploy applications to Firebase using the [firebase plugin](https://github.com/fluent-ci-templates/firebase-pipeline), no need to install Firebase CLI on your machine, FluentCI will handle everything for you. - -The following commands can be used to deploy applications to Firebase: - -```bash -# Deploy to Firebase, make sure to export FIREBASE_TOKEN and DEPLOY_DIRECTORY -fluentci run --wasm firebase build -fluentci run --wasm firebase deploy -``` diff --git a/docs/cookbook/deploy-to-firebase.mdx b/docs/cookbook/deploy-to-firebase.mdx new file mode 100644 index 0000000..9c021be --- /dev/null +++ b/docs/cookbook/deploy-to-firebase.mdx @@ -0,0 +1,140 @@ +--- +sidebar_position: 14 +--- + +# Deploy to Firebase + +This page explains how to deploy applications to Firebase using FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Firebase`. In addition: + +- Have your Firebase project ready. +- If you don't already have a project to deploy to Firebase, you can create a default project by [installing and initializing Firebase](https://firebase.google.com/docs/hosting/quickstart#initialize). + +## Using the Firebase Plugin + +You can use FluentCI to deploy applications to Firebase using the [firebase plugin](https://github.com/fluent-ci-templates/firebase-pipeline), no need to install Firebase CLI on your machine, FluentCI will handle everything for you. + +The following commands can be used to deploy applications to Firebase: + +```bash +# Deploy to Firebase, make sure to export FIREBASE_TOKEN environment variable +fluentci run --wasm firebase deploy +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to deploy applications to Firebase: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: deploy + run: fluentci run --wasm firebase deploy + env: + FIREBASE_TOKEN: \${{ secrets.FIREBASE_TOKEN }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + FIREBASE_TOKEN: $FIREBASE_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +deploy: + extends: .fluentci + script: + - fluentci run --wasm firebase deploy +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm firebase deploy + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm firebase deploy + displayName: deploy + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm firebase deploy + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/deploy-to-fly.md b/docs/cookbook/deploy-to-fly.md deleted file mode 100644 index bdafa91..0000000 --- a/docs/cookbook/deploy-to-fly.md +++ /dev/null @@ -1,28 +0,0 @@ ---- -sidebar_position: 15 ---- - -# Deploy to Fly.io - -This page explains how to deploy applications to [fly.io](https://fly.io) using FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `fly.io`. In addition: - -- Have your Fly.io project ready. -- Have your application ready. -- Have a `fly.toml` file in the root of your project. -- If you don't already have a project to deploy to Fly.io, you can create a default project by [installing and initializing Fly.io](https://fly.io/docs/getting-started/installing-flyctl/). - -## Using the Fly.io Plugin - -You can use FluentCI to deploy applications to Fly.io using the [fly.io plugin](https://github.com/fluent-ci-templates/fly-pipeline), no need to install Fly.io CLI on your machine, FluentCI will handle everything for you. - -The following commands can be used to deploy applications to `fly.io`: - -```bash -# Deploy to Fly.io, make sure to export FLY_API_TOKEN -fluentci run --wasm fly deploy -``` - diff --git a/docs/cookbook/deploy-to-fly.mdx b/docs/cookbook/deploy-to-fly.mdx new file mode 100644 index 0000000..faef3d1 --- /dev/null +++ b/docs/cookbook/deploy-to-fly.mdx @@ -0,0 +1,149 @@ +--- +sidebar_position: 15 +--- + +# Deploy to Fly.io + +This page explains how to deploy applications to [fly.io](https://fly.io) using FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `fly.io`. In addition: + +- Have your Fly.io project ready. +- Have your application ready. +- Have a `fly.toml` file in the root of your project. +- If you don't already have a project to deploy to Fly.io, you can create a default project by [installing and initializing Fly.io](https://fly.io/docs/getting-started/installing-flyctl/). + +## Using the Fly.io Plugin + +You can use FluentCI to deploy applications to Fly.io using the [fly.io plugin](https://github.com/fluent-ci-templates/fly-pipeline), no need to install Fly.io CLI on your machine, FluentCI will handle everything for you. + +The following commands can be used to deploy applications to `fly.io`: + +```bash +# Deploy to Fly.io, make sure to export FLY_API_TOKEN +fluentci run --wasm fly deploy +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to deploy applications to Fly.io: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: deploy + run: fluentci run --wasm fly deploy + env: + FLY_API_TOKEN: \${{ secrets.FLY_API_TOKEN }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + FLY_API_TOKEN: $FLY_API_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +deploy: + extends: .fluentci + script: + - fluentci run --wasm fly deploy +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm fly deploy + name: deploy + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm fly deploy + displayName: deploy + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm fly deploy + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/deploy-to-heroku.md b/docs/cookbook/deploy-to-heroku.md deleted file mode 100644 index 0a75be0..0000000 --- a/docs/cookbook/deploy-to-heroku.md +++ /dev/null @@ -1,26 +0,0 @@ ---- -sidebar_position: 16 ---- - -# Deploy to Heroku - -This page explains how to deploy applications to Heroku using FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Heroku`. In addition: - -- Have your Heroku project ready. -- Have a `Procfile` in your project root directory. -- If you don't already have a project to deploy to Heroku, you can create a default project by [installing and initializing Heroku](https://devcenter.heroku.com/). - -## Using the Heroku Plugin - -You can use FluentCI to deploy applications to Heroku using the [heroku plugin](https://github.com/fluent-ci-templates/heroku-pipeline), no need to install Heroku CLI on your machine, FluentCI will handle everything for you. - -The following commands can be used to deploy applications to Heroku: - -```bash -# Deploy to Heroku, make sure to export HEROKU_API_KEY and HEROKU_APP_NAME -fluentci run --wasm heroku deploy --app $HEROKU_APP_NAME --api_key $HEROKU_API_KEY -``` diff --git a/docs/cookbook/deploy-to-heroku.mdx b/docs/cookbook/deploy-to-heroku.mdx new file mode 100644 index 0000000..5cc8970 --- /dev/null +++ b/docs/cookbook/deploy-to-heroku.mdx @@ -0,0 +1,150 @@ +--- +sidebar_position: 16 +--- + +# Deploy to Heroku + +This page explains how to deploy applications to Heroku using FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Heroku`. In addition: + +- Have your Heroku project ready. +- Have a `Procfile` in your project root directory. +- If you don't already have a project to deploy to Heroku, you can create a default project by [installing and initializing Heroku](https://devcenter.heroku.com/). + +## Using the Heroku Plugin + +You can use FluentCI to deploy applications to Heroku using the [heroku plugin](https://github.com/fluent-ci-templates/heroku-pipeline), no need to install Heroku CLI on your machine, FluentCI will handle everything for you. + +The following commands can be used to deploy applications to Heroku: + +```bash +# Deploy to Heroku, make sure to export HEROKU_API_KEY and HEROKU_APP_NAME +fluentci run --wasm heroku deploy --app $HEROKU_APP_NAME --api_key $HEROKU_API_KEY +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to deploy applications to Heroku: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: deploy + run: fluentci run --wasm heroku deploy --app $HEROKU_APP_NAME --api_key $HEROKU_API_KEY + env: + HEROKU_APP_NAME: \${{ secrets.HEROKU_APP_NAME }} + HEROKU_API_KEY: \${{ secrets.HEROKU_API_KEY }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + HEROKU_API_KEY: $HEROKU_API_KEY + HEROKU_APP_NAME: $HEROKU_APP_NAME +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +deploy: + extends: .fluentci + script: + - fluentci run --wasm heroku deploy +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm heroku deploy --app $HEROKU_APP_NAME --api_key $HEROKU_API_KEY + name: deploy + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm heroku deploy --app $HEROKU_APP_NAME --api_key $HEROKU_API_KEY + displayName: deploy + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm heroku deploy --app $HEROKU_APP_NAME --api_key $HEROKU_API_KEY + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/deploy-to-netlify.md b/docs/cookbook/deploy-to-netlify.md deleted file mode 100644 index 5e82026..0000000 --- a/docs/cookbook/deploy-to-netlify.md +++ /dev/null @@ -1,25 +0,0 @@ ---- -sidebar_position: 17 ---- - -# Deploy to Netlify - -This page explains how to deploy applications to Netlify using FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Netlify`. In addition: - -- Have your Netlify project ready. -- If you don't already have a project to deploy to Netlify, you can create a default project by [installing and initializing Netlify](https://docs.netlify.com/get-started/). - -## Using the Netlify Plugin - -You can use FluentCI to deploy applications to Netlify using the [netlify plugin](https://github.com/fluent-ci-templates/netlify-pipeline), no need to install Netlify CLI or Node.js on your machine, FluentCI will handle everything for you. - -The following commands can be used to deploy applications to Netlify: - -```bash -# Deploy to Netlify, make sure to export NETLIFY_AUTH_TOKEN, NETLIFY_SITE_ID and NETLIFY_SITE_DIR -fluentci run --wasm netlify deploy --dir $NETLIFY_SITE_DIR -``` diff --git a/docs/cookbook/deploy-to-netlify.mdx b/docs/cookbook/deploy-to-netlify.mdx new file mode 100644 index 0000000..0487db2 --- /dev/null +++ b/docs/cookbook/deploy-to-netlify.mdx @@ -0,0 +1,151 @@ +--- +sidebar_position: 17 +--- + +# Deploy to Netlify + +This page explains how to deploy applications to Netlify using FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Netlify`. In addition: + +- Have your Netlify project ready. +- If you don't already have a project to deploy to Netlify, you can create a default project by [installing and initializing Netlify](https://docs.netlify.com/get-started/). + +## Using the Netlify Plugin + +You can use FluentCI to deploy applications to Netlify using the [netlify plugin](https://github.com/fluent-ci-templates/netlify-pipeline), no need to install Netlify CLI or Node.js on your machine, FluentCI will handle everything for you. + +The following commands can be used to deploy applications to Netlify: + +```bash +# Deploy to Netlify, make sure to export NETLIFY_AUTH_TOKEN, NETLIFY_SITE_ID and NETLIFY_SITE_DIR +fluentci run --wasm netlify deploy --dir $NETLIFY_SITE_DIR +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to deploy applications to Netlify: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: deploy + run: fluentci run --wasm netlify deploy --dir $NETLIFY_SITE_DIR + env: + NETLIFY_AUTH_TOKEN: \${{ secrets.NETLIFY_AUTH_TOKEN }} + NETLIFY_SITE_ID: \${{ env.NETLIFY_SITE_ID }} + NETLIFY_SITE_DIR: \${{ env.NETLIFY_SITE_DIR }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + NETLIFY_AUTH_TOKEN: $NETLIFY_AUTH_TOKEN + NETLIFY_SITE_ID: $NETLIFY_SITE_ID + NETLIFY_SITE_DIR: $NETLIFY_SITE_DIR +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +deploy: + extends: .fluentci + script: + - fluentci run --wasm netlify deploy --dir $NETLIFY_SITE_DIR +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm netlify deploy --dir $NETLIFY_SITE_DIR + name: deploy + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm netlify deploy --dir $NETLIFY_SITE_DIR + displayName: deploy + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm netlify deploy --dir $NETLIFY_SITE_DIR + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/deploy-to-railway.md b/docs/cookbook/deploy-to-railway.md deleted file mode 100644 index 6f8a212..0000000 --- a/docs/cookbook/deploy-to-railway.md +++ /dev/null @@ -1,25 +0,0 @@ ---- -sidebar_position: 18 ---- - -# Deploy to Railway - -This page explains how to deploy applications to Railway using FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Railway`. In addition: - -- Have your Railway project ready. -- If you don't already have a project to deploy to Railway, you can create a default project by [installing and initializing Railway](https://docs.railway.app/getting-started). - -## Using the Railway Plugin - -You can use FluentCI to deploy applications to Railway using the [railway plugin](https://github.com/fluent-ci-templates/railway-pipeline), no need to install Railway CLI on your machine, FluentCI will handle everything for you. - -The following commands can be used to deploy applications to Railway: - -```bash -# Deploy to Railway, make sure to export RAILWAY_TOKEN -fluentci run --wasm railway deploy -``` diff --git a/docs/cookbook/deploy-to-railway.mdx b/docs/cookbook/deploy-to-railway.mdx new file mode 100644 index 0000000..5cfdf5a --- /dev/null +++ b/docs/cookbook/deploy-to-railway.mdx @@ -0,0 +1,147 @@ +--- +sidebar_position: 18 +--- + +# Deploy to Railway + +This page explains how to deploy applications to Railway using FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Railway`. In addition: + +- Have your Railway project ready. +- If you don't already have a project to deploy to Railway, you can create a default project by [installing and initializing Railway](https://docs.railway.app/getting-started). + +## Using the Railway Plugin + +You can use FluentCI to deploy applications to Railway using the [railway plugin](https://github.com/fluent-ci-templates/railway-pipeline), no need to install Railway CLI on your machine, FluentCI will handle everything for you. + +The following commands can be used to deploy applications to Railway: + +```bash +# Deploy to Railway, make sure to export RAILWAY_TOKEN +fluentci run --wasm railway deploy +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to deploy applications to Railway: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: deploy + run: fluentci run --wasm railway deploy + env: + RAILWAY_TOKEN: \${{ secrets.RAILWAY_TOKEN }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + RAILWAY_TOKEN: $RAILWAY_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +deploy: + extends: .fluentci + script: + - fluentci run --wasm railway deploy +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm railway deploy + name: deploy + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm railway deploy + displayName: deploy + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm railway deploy + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/deploy-to-shuttle.md b/docs/cookbook/deploy-to-shuttle.md deleted file mode 100644 index b37140d..0000000 --- a/docs/cookbook/deploy-to-shuttle.md +++ /dev/null @@ -1,25 +0,0 @@ ---- -sidebar_position: 19 ---- - -# Deploy to Shuttle - -This page explains how to deploy applications to Shuttle using FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Shuttle`. In addition: - -- Have your Shuttle project ready. -- If you don't already have a project to deploy to Shuttle, you can create a default project by [installing and initializing Shuttle](https://docs.shuttle.rs/getting-started/installation). - -## Using the Shuttle Plugin - -You can use FluentCI to deploy applications to Shuttle using the [shuttle plugin](https://github.com/fluent-ci-templates/shuttle-pipeline), no need to install Shuttle CLI on your machine, FluentCI will handle everything for you. - -The following commands can be used to deploy applications to Shuttle: - -```bash -# Deploy to Shuttle, make sure to export SHUTTLE_API_KEY -fluentci run --wasm shuttle deploy -``` diff --git a/docs/cookbook/deploy-to-shuttle.mdx b/docs/cookbook/deploy-to-shuttle.mdx new file mode 100644 index 0000000..63d94c3 --- /dev/null +++ b/docs/cookbook/deploy-to-shuttle.mdx @@ -0,0 +1,147 @@ +--- +sidebar_position: 19 +--- + +# Deploy to Shuttle + +This page explains how to deploy applications to Shuttle using FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Shuttle`. In addition: + +- Have your Shuttle project ready. +- If you don't already have a project to deploy to Shuttle, you can create a default project by [installing and initializing Shuttle](https://docs.shuttle.rs/getting-started/installation). + +## Using the Shuttle Plugin + +You can use FluentCI to deploy applications to Shuttle using the [shuttle plugin](https://github.com/fluent-ci-templates/shuttle-pipeline), no need to install Shuttle CLI on your machine, FluentCI will handle everything for you. + +The following commands can be used to deploy applications to Shuttle: + +```bash +# Deploy to Shuttle, make sure to export SHUTTLE_API_KEY +fluentci run --wasm shuttle deploy +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to deploy applications to Shuttle: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: deploy + run: fluentci run --wasm shuttle deploy + env: + SHUTTLE_API_KEY: \${{ secrets.SHUTTLE_API_KEY }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + SHUTTLE_API_KEY: $SHUTTLE_API_KEY +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +deploy: + extends: .fluentci + script: + - fluentci run --wasm shuttle deploy +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm shuttle deploy + name: deploy + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm shuttle deploy + displayName: deploy + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm shuttle deploy + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/deploy-to-spin.md b/docs/cookbook/deploy-to-spin.md deleted file mode 100644 index bd64489..0000000 --- a/docs/cookbook/deploy-to-spin.md +++ /dev/null @@ -1,26 +0,0 @@ ---- -sidebar_position: 20 ---- - -# Deploy to Fermyon Cloud - -This page explains how to deploy applications to Fermyon CLoud using FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Fermyon Cloud`. In addition: - -- Have your Spin project ready. -- If you don't already have a project to deploy to Fermyon Cloud, you can create a default project by [installing and initializing Spin](https://developer.fermyon.com/cloud/quickstart). - -## Using the Spin Plugin - -You can use FluentCI to deploy applications to Fermyon Cloud using the [spin plugin](https://github.com/fluent-ci-templates/spin-pipeline), no need to install Spin CLI on your machine, FluentCI will handle everything for you. - -The following commands can be used to deploy applications to Fermyon Cloud: - -```bash -# Deploy to Fermyon Cloud, make sure to export SPIN_AUTH_TOKEN -fluentci run --wasm spin build -fluentci run --wasm spin deploy -``` diff --git a/docs/cookbook/deploy-to-spin.mdx b/docs/cookbook/deploy-to-spin.mdx new file mode 100644 index 0000000..b60b977 --- /dev/null +++ b/docs/cookbook/deploy-to-spin.mdx @@ -0,0 +1,159 @@ +--- +sidebar_position: 20 +--- + +# Deploy to Fermyon Cloud + +This page explains how to deploy applications to Fermyon CLoud using FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Fermyon Cloud`. In addition: + +- Have your Spin project ready. +- If you don't already have a project to deploy to Fermyon Cloud, you can create a default project by [installing and initializing Spin](https://developer.fermyon.com/cloud/quickstart). + +## Using the Spin Plugin + +You can use FluentCI to deploy applications to Fermyon Cloud using the [spin plugin](https://github.com/fluent-ci-templates/spin-pipeline), no need to install Spin CLI on your machine, FluentCI will handle everything for you. + +The following commands can be used to deploy applications to Fermyon Cloud: + +```bash +# Deploy to Fermyon Cloud, make sure to export SPIN_AUTH_TOKEN +fluentci run --wasm spin build +fluentci run --wasm spin deploy +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to deploy applications to Fermyon Cloud: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: build + run: fluentci run --wasm spin build + - name: deploy + run: fluentci run --wasm spin deploy + env: + SPIN_AUTH_TOKEN: \${{ secrets.SPIN_AUTH_TOKEN }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + SPIN_AUTH_TOKEN: $SPIN_AUTH_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +build: + extends: .fluentci + script: + - fluentci run --wasm spin build +deploy: + extends: .fluentci + script: + - fluentci run --wasm spin deploy +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm spin build + name: build + - run: fluentci run --wasm spin deploy + name: deploy + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm spin build + displayName: build + - script: fluentci run --wasm spin deploy + displayName: deploy + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm spin build + - fluentci run --wasm spin deploy + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/deploy-to-wasmer.md b/docs/cookbook/deploy-to-wasmer.md deleted file mode 100644 index 31b6ef9..0000000 --- a/docs/cookbook/deploy-to-wasmer.md +++ /dev/null @@ -1,26 +0,0 @@ ---- -sidebar_position: 21 ---- - -# Deploy to Wasmer Edge - -This page explains how to deploy applications to Wasmer Edge using FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Wasmer`. In addition: - -- Have your Wasmer project ready. -- If you don't already have a project to deploy to Wasmer Edge, you can create a default project by [installing and initializing Wasmer](https://docs.wasmer.io/edge/get-started). - -## Using the Wasmer Plugin - -You can use FluentCI to deploy applications to Wasmer Edge using the [wasmer plugin](https://github.com/fluent-ci-templates/wasmer-pipeline), no need to install Wasmer CLI on your machine, FluentCI will handle everything for you. - -The following commands can be used to deploy applications to Wasmer Edge: - -```bash -fluentci run --wasm wasmer build -# Deploy to Wasmer Edge, make sure to export WASMER_TOKEN -fluentci run --wasm wasmer deploy -``` diff --git a/docs/cookbook/deploy-to-wasmer.mdx b/docs/cookbook/deploy-to-wasmer.mdx new file mode 100644 index 0000000..804d9d0 --- /dev/null +++ b/docs/cookbook/deploy-to-wasmer.mdx @@ -0,0 +1,159 @@ +--- +sidebar_position: 21 +--- + +# Deploy to Wasmer Edge + +This page explains how to deploy applications to Wasmer Edge using FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Wasmer`. In addition: + +- Have your Wasmer project ready. +- If you don't already have a project to deploy to Wasmer Edge, you can create a default project by [installing and initializing Wasmer](https://docs.wasmer.io/edge/get-started). + +## Using the Wasmer Plugin + +You can use FluentCI to deploy applications to Wasmer Edge using the [wasmer plugin](https://github.com/fluent-ci-templates/wasmer-pipeline), no need to install Wasmer CLI on your machine, FluentCI will handle everything for you. + +The following commands can be used to deploy applications to Wasmer Edge: + +```bash +fluentci run --wasm wasmer build +# Deploy to Wasmer Edge, make sure to export WASMER_TOKEN +fluentci run --wasm wasmer deploy +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to deploy applications to Wasmer Edge: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: build + run: fluentci run --wasm wasmer build + - name: deploy + run: fluentci run --wasm wasmer deploy + env: + WASMER_TOKEN: \${{ secrets.WASMER_TOKEN }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + WASMER_TOKEN: $WASMER_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +build: + extends: .fluentci + script: + - fluentci run --wasm wasmer build +deploy: + extends: .fluentci + script: + - fluentci run --wasm wasmer deploy +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm wasmer build + name: build + - run: fluentci run --wasm wasmer deploy + name: deploy + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm wasmer build + displayName: build + - script: fluentci run --wasm wasmer deploy + displayName: deploy + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm wasmer build + - fluentci run --wasm wasmer deploy + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/provision-with-pulumi.md b/docs/cookbook/provision-with-pulumi.md deleted file mode 100644 index 5e4caa8..0000000 --- a/docs/cookbook/provision-with-pulumi.md +++ /dev/null @@ -1,29 +0,0 @@ ---- -sidebar_position: 22 ---- - -# Provision with Pulumi - -This page explains how to provision infrastructure using [Pulumi](https://pulumi.com) with FluentCI. - -Pulumi is an infrastructure-as-code (IaC) tool that lets you provision and manage cloud infrastructure. Pulumi provides plugins called providers that let you interact with cloud providers and other APIs. - -## Before you begin - -The instructions on this page assume that you are familiar with `Pulumi`. In addition: - -- Have your Pulumi project ready. -- If you don't already have a project to provision with Pulumi, you can create a default project by [installing and initializing Pulumi](https://www.pulumi.com/docs/install/). -- Make sure you have a `Pulumi.yaml` file in your project root directory. -- Make sure you have a `Pulumi.dev.yaml` file in your project root directory. - -## Using the Pulumi Plugin - -You can use FluentCI to provision infrastructure using Pulumi with the [pulumi plugin](https://github.com/fluent-ci-templates/pulumi-pipeline) without installing Pulumi CLI on your machine. FluentCI will handle everything for you. - -The following commands can be used to provision infrastructure using Pulumi: - -```bash -fluentci run --wasm pulumi init -fluentci run --wasm pulumi up -``` diff --git a/docs/cookbook/provision-with-pulumi.mdx b/docs/cookbook/provision-with-pulumi.mdx new file mode 100644 index 0000000..f8cdf1d --- /dev/null +++ b/docs/cookbook/provision-with-pulumi.mdx @@ -0,0 +1,166 @@ +--- +sidebar_position: 22 +--- + +# Provision with Pulumi + +This page explains how to provision infrastructure using [Pulumi](https://pulumi.com) with FluentCI. + +Pulumi is an infrastructure-as-code (IaC) tool that lets you provision and manage cloud infrastructure. Pulumi provides plugins called providers that let you interact with cloud providers and other APIs. + +## Before you begin + +The instructions on this page assume that you are familiar with `Pulumi`. In addition: + +- Have your Pulumi project ready. +- If you don't already have a project to provision with Pulumi, you can create a default project by [installing and initializing Pulumi](https://www.pulumi.com/docs/install/). +- Make sure you have a `Pulumi.yaml` file in your project root directory. +- Make sure you have a `Pulumi.dev.yaml` file in your project root directory. + +## Using the Pulumi Plugin + +You can use FluentCI to provision infrastructure using Pulumi with the [pulumi plugin](https://github.com/fluent-ci-templates/pulumi-pipeline) without installing Pulumi CLI on your machine. FluentCI will handle everything for you. + +The following commands can be used to provision infrastructure using Pulumi: + +```bash +fluentci run --wasm pulumi preview --stack dev +fluentci run --wasm pulumi up --stack dev +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to provision infrastructure using Pulumi: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: preview + run: fluentci run --wasm pulumi preview --stack dev + env: + GOOGLE_APPLICATION_CREDENTIALS: ./service-account.json + PULUMI_ACCESS_TOKEN: \${{ secrets.PULUMI_ACCESS_TOKEN }} + - name: up + run: fluentci run --wasm pulumi up --stack dev + env: + GOOGLE_APPLICATION_CREDENTIALS: ./service-account.json + PULUMI_ACCESS_TOKEN: \${{ secrets.PULUMI_ACCESS_TOKEN }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + GOOGLE_APPLICATION_CREDENTIALS: ./service-account.json + PULUMI_ACCESS_TOKEN: $PULUMI_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +preview: + extends: .fluentci + script: + - fluentci run --wasm pulumi preview --stack dev +up: + extends: .fluentci + script: + - fluentci run --wasm pulumi up --stack dev +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm pulumi preview --stack dev + name: preview + - run: fluentci run --wasm pulumi up --stack dev + name: up + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm pulumi preview --stack dev + displayName: preview + - script: fluentci run --wasm pulumi up --stack dev + displayName: up + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm pulumi preview --stack dev + - fluentci run --wasm pulumi up --stack dev + post_build: + commands: + - echo Build completed on \`date\``} + + + diff --git a/docs/cookbook/provision-with-terraform.md b/docs/cookbook/provision-with-terraform.md deleted file mode 100644 index 0f8a1a9..0000000 --- a/docs/cookbook/provision-with-terraform.md +++ /dev/null @@ -1,29 +0,0 @@ ---- -sidebar_position: 23 ---- - -# Provision with Terraform - -This page explains how to provision infrastructure using [Terraform](https://terraform.io) with FluentCI. - -HashiCorp Terraform is an infrastructure-as-code (IaC) tool that lets you provision and manage cloud infrastructure. Terraform provides plugins called providers that let you interact with cloud providers and other APIs. - -## Before you begin - -The instructions on this page assume that you are familiar with `Terraform`. In addition: - -- Have your Terraform project ready. -- If you don't already have a project to provision with Terraform, you can create a default project by [installing and initializing Terraform](https://developer.hashicorp.com/terraform/tutorials/aws-get-started/install-cli). -- Make sure you have a `main.tf` file in your project root directory. - -## Using the Terraform Plugin - -You can use FluentCI to provision infrastructure using Terraform with the [terraform plugin](https://github.com/fluent-ci-templates/terraform-pipeline) without installing Terraform CLI on your machine. FluentCI will handle everything for you. - -The following commands can be used to provision infrastructure using Terraform: - -```bash -fluentci run --wasm terraform init -fluentci run --wasm terraform plan -fluentci run --wasm terraform apply -``` diff --git a/docs/cookbook/provision-with-terraform.mdx b/docs/cookbook/provision-with-terraform.mdx new file mode 100644 index 0000000..aa260f6 --- /dev/null +++ b/docs/cookbook/provision-with-terraform.mdx @@ -0,0 +1,190 @@ +--- +sidebar_position: 23 +--- + +# Provision with Terraform + +This page explains how to provision infrastructure using [Terraform](https://terraform.io) with FluentCI. + +HashiCorp Terraform is an infrastructure-as-code (IaC) tool that lets you provision and manage cloud infrastructure. Terraform provides plugins called providers that let you interact with cloud providers and other APIs. + +## Before you begin + +The instructions on this page assume that you are familiar with `Terraform`. In addition: + +- Have your Terraform project ready. +- If you don't already have a project to provision with Terraform, you can create a default project by [installing and initializing Terraform](https://developer.hashicorp.com/terraform/tutorials/aws-get-started/install-cli). +- Make sure you have a `main.tf` file in your project root directory. + +## Using the Terraform Plugin + +You can use FluentCI to provision infrastructure using Terraform with the [terraform plugin](https://github.com/fluent-ci-templates/terraform-pipeline) without installing Terraform CLI on your machine. FluentCI will handle everything for you. + +The following commands can be used to provision infrastructure using Terraform: + +```bash +fluentci run --wasm terraform init +fluentci run --wasm terraform plan +fluentci run --wasm terraform apply +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to provision infrastructure using Terraform: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: init + run: fluentci run --wasm terraform init + env: + GOOGLE_APPLICATION_CREDENTIALS: ./service-account.json + - name: validate + run: fluentci run --wasm terraform validate + env: + GOOGLE_APPLICATION_CREDENTIALS: ./service-account.json + - name: plan + run: fluentci run --wasm terraform plan + env: + GOOGLE_APPLICATION_CREDENTIALS: ./service-account.json + - name: apply + run: fluentci run --wasm terraform apply + env: + GOOGLE_APPLICATION_CREDENTIALS: ./service-account.json + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + GOOGLE_APPLICATION_CREDENTIALS: ./service-account.json +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +init: + extends: .fluentci + script: + - fluentci run --wasm terraform init +validate: + extends: .fluentci + script: + - fluentci run --wasm terraform validate +plan: + extends: .fluentci + script: + - fluentci run --wasm terraform plan +apply: + extends: .fluentci + script: + - fluentci run --wasm terraform apply +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm terraform init + name: init + - run: fluentci run --wasm terraform validate + name: validate + - run: fluentci run --wasm terraform plan + name: plan + - run: fluentci run --wasm terraform apply + name: apply + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm terraform init + displayName: init + - script: fluentci run --wasm terraform validate + displayName: validate + - script: fluentci run --wasm terraform plan + displayName: plan + - script: fluentci run --wasm terraform apply + displayName: apply + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm terraform init + - fluentci run --wasm terraform validate + - fluentci run --wasm terraform plan + - fluentci run --wasm terraform apply + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/upload-to-codecov.md b/docs/cookbook/upload-to-codecov.md deleted file mode 100644 index 1c8008d..0000000 --- a/docs/cookbook/upload-to-codecov.md +++ /dev/null @@ -1,27 +0,0 @@ ---- -sidebar_position: 24 ---- - -# Upload Coverage to Codecov - -This page explains how to upload coverage reports to Codecov with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Codecov`. In addition: - -- Have your project ready, including the coverage report. -- Have a Codecov account. -- Have a Codecov token. -- Have a Codecov project. - -## Using the Codecov Plugin - -You can use FluentCI to upload coverage reports to Codecov using the [codecov plugin](https://github.com/fluent-ci-templates/codecov-pipeline), no need to install Codecov CLI on your machine, FluentCI will handle everything for you. - -The following command can be used to upload coverage reports to Codecov: - -```bash -# Make sure to set the CODECOV_TOKEN environment variable -fluentci run --wasm codecov upload -``` diff --git a/docs/cookbook/upload-to-codecov.mdx b/docs/cookbook/upload-to-codecov.mdx new file mode 100644 index 0000000..2fa954a --- /dev/null +++ b/docs/cookbook/upload-to-codecov.mdx @@ -0,0 +1,146 @@ +--- +sidebar_position: 24 +--- + +# Upload Coverage to Codecov + +This page explains how to upload coverage reports to Codecov with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Codecov`. In addition: + +- Have your project ready, including the coverage report. +- Have a Codecov account. +- Have a Codecov token. +- Have a Codecov project. + +## Using the Codecov Plugin + +You can use FluentCI to upload coverage reports to Codecov using the [codecov plugin](https://github.com/fluent-ci-templates/codecov-pipeline), no need to install Codecov CLI on your machine, FluentCI will handle everything for you. + +The following command can be used to upload coverage reports to Codecov: + +```bash +# Make sure to set the CODECOV_TOKEN environment variable +fluentci run --wasm codecov upload +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to upload coverage reports to Codecov: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: upload + run: fluentci run --wasm codecov upload + env: + CODECOV_TOKEN: \${{ secrets.CODECOV_TOKEN }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + CODECOV_TOKEN: $CODECOV_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +upload: + extends: .fluentci + script: + - fluentci run --wasm codecov upload +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm codecov upload + name: upload + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm codecov upload + displayName: upload`} + + + + +{`# Do not edit this file directly. It is generated by https://deno.land/x/fluent_aws_codepipeline + +version: 0.2 +phases: +install: +commands: - curl -fsSL https://cli.fluentci.io | bash - fluentci --version +build: +commands: - fluentci run --wasm codecov upload +post_build: +commands: - echo Build completed on \`date\``} + + + + diff --git a/docs/cookbook/upload-to-github-releases.md b/docs/cookbook/upload-to-github-releases.md deleted file mode 100644 index a1f6645..0000000 --- a/docs/cookbook/upload-to-github-releases.md +++ /dev/null @@ -1,29 +0,0 @@ ---- -sidebar_position: 25 ---- - -# Upload assets to GitHub - -This page explains how to upload assets to GitHub Releases with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `GitHub Releases`. In addition: - -- Have your project ready, including the assets you want to upload. -- Have a GitHub account. -- Have a GitHub repository. -- Have a GitHub token. - -## Using the GitHub Plugin - -You can use FluentCI to upload assets to GitHub Releases using the [github plugin](https://github.com/fluent-ci-templates/github-pipeline), no need to install GitHub CLI on your machine, FluentCI will handle everything for you. - -The following command can be used to upload assets to GitHub Releases: - -```bash -# Make sure to set the GH_TOKEN environment variable -fluentci run --wasm github release_upload $TAG $ASSET_PATH -``` - - diff --git a/docs/cookbook/upload-to-github-releases.mdx b/docs/cookbook/upload-to-github-releases.mdx new file mode 100644 index 0000000..31c72ba --- /dev/null +++ b/docs/cookbook/upload-to-github-releases.mdx @@ -0,0 +1,150 @@ +--- +sidebar_position: 25 +--- + +# Upload assets to GitHub + +This page explains how to upload assets to GitHub Releases with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `GitHub Releases`. In addition: + +- Have your project ready, including the assets you want to upload. +- Have a GitHub account. +- Have a GitHub repository. +- Have a GitHub token. + +## Using the GitHub Plugin + +You can use FluentCI to upload assets to GitHub Releases using the [github plugin](https://github.com/fluent-ci-templates/github-pipeline), no need to install GitHub CLI on your machine, FluentCI will handle everything for you. + +The following command can be used to upload assets to GitHub Releases: + +```bash +# Make sure to set the GH_TOKEN environment variable +fluentci run --wasm github release_upload $TAG $ASSET_PATH +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to upload assets to GitHub Releases: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: upload release assets + run: |- + fluentci run --wasm github release_upload $TAG $FILE # Replace $TAG and $FILE with your values + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + GITHUB_TOKEN: $GITHUB_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +release_upload $TAG $FILE: + extends: .fluentci + script: + - fluentci run --wasm github release_upload $TAG $FILE # replace $TAG and $FILE with your values +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: | + fluentci run --wasm github release_upload $TAG $FILE # Replace $TAG and $FILE with your values + name: upload release assets + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: |- + fluentci run --wasm github release_upload $TAG $FILE # Replace $TAG and $FILE with your values + displayName: upload release assets + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm github release_upload $TAG $FILE # Replace $TAG and $FILE with your values + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/upload-to-gitlab.md b/docs/cookbook/upload-to-gitlab.md deleted file mode 100644 index d830331..0000000 --- a/docs/cookbook/upload-to-gitlab.md +++ /dev/null @@ -1,27 +0,0 @@ ---- -sidebar_position: 26 ---- - -# Upload assets to GitLab Releases - -This page explains how to upload assets to GitLab Releases with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `GitLab Releases`. In addition: - -- Have your project ready, including the assets you want to upload. -- Have a GitLab account. -- Have a GitLab repository. -- Have a GitLab token. - -## Using the GitLab Plugin - -You can use FluentCI to upload assets to GitLab Releases using the [gitlab plugin](https://github.com/fluent-ci-templates/gitlab-pipeline), no need to install GitLab CLI on your machine, FluentCI will handle everything for you. - -The following command can be used to upload assets to GitLab Releases: - -```bash -# Make sure to set the GITLAB_ACCESS_TOKEN environment variable -fluentci run --wasm gitlab release_upload $TAG $FILE -``` diff --git a/docs/cookbook/upload-to-gitlab.mdx b/docs/cookbook/upload-to-gitlab.mdx new file mode 100644 index 0000000..840f0e0 --- /dev/null +++ b/docs/cookbook/upload-to-gitlab.mdx @@ -0,0 +1,161 @@ +--- +sidebar_position: 26 +--- + +# Upload assets to GitLab Releases + +This page explains how to upload assets to GitLab Releases with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `GitLab Releases`. In addition: + +- Have your project ready, including the assets you want to upload. +- Have a GitLab account. +- Have a GitLab repository. +- Have a GitLab token. + +## Using the GitLab Plugin + +You can use FluentCI to upload assets to GitLab Releases using the [gitlab plugin](https://github.com/fluent-ci-templates/gitlab-pipeline), no need to install GitLab CLI on your machine, FluentCI will handle everything for you. + +The following command can be used to upload assets to GitLab Releases: + +```bash +# Make sure to set the GITLAB_ACCESS_TOKEN environment variable +fluentci run --wasm gitlab release_upload $TAG $FILE +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to upload assets to GitLab Releases: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: release_create + run: fluentci run --wasm gitlab release_create $TAG # Replace $TAG with the tag name + env: + GITLAB_ACCESS_TOKEN: \${{ secrets.GITLAB_ACCESS_TOKEN }} + - name: release_upload + run: fluentci run --wasm gitlab release_upload $TAG $FILE # Replace $TAG with the tag name and $FILE with the file path + env: + GITLAB_ACCESS_TOKEN: \${{ secrets.GITLAB_ACCESS_TOKEN }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +release_create: + extends: .fluentci + script: + - fluentci run --wasm gitlab release_create $TAG # Replace $TAG with the tag name +release_upload: + extends: .fluentci + script: + - fluentci run --wasm gitlab release_upload $TAG $FILE # Replace $TAG with the tag name and $FILE with the file path +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm gitlab release_create $TAG # Replace $TAG with the tag name + name: release_create + - run: fluentci run --wasm gitlab release_upload $TAG $FILE # Replace $TAG with the tag name and $FILE with the file path + name: release_upload + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm gitlab release_create $TAG # Replace $TAG with the tag name + displayName: release_create + - script: fluentci run --wasm gitlab release_upload $TAG $FILE # Replace $TAG with the tag name and $FILE with the file path + displayName: release_upload + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm gitlab release_create $TAG # Replace $TAG with the tag name + - fluentci run --wasm gitlab release_upload $TAG $FILE # Replace $TAG with the tag name and $FILE with the file path + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/upload-to-r2.md b/docs/cookbook/upload-to-r2.md deleted file mode 100644 index a8e52ed..0000000 --- a/docs/cookbook/upload-to-r2.md +++ /dev/null @@ -1,28 +0,0 @@ ---- -sidebar_position: 27 ---- - -# Upload files to Cloudflare R2 - -This page explains how to upload files to Cloudflare R2 with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `Cloudflare R2`. In addition: - -- Have your project ready, including the files you want to upload. -- Have a Cloudflare account. -- Have a Cloudflare R2 Bucket. -- Have a Cloudflare R2 Access Key. -- Have a Cloudflare R2 Secret Key. - -## Using the R2 Plugin - -You can use FluentCI to upload files to Cloudflare R2 using the [r2-sync plugin](https://github.com/tsirysndr/daggerverse/tree/main/r2-sync), no need to install AWS CLI on your machine, FluentCI will handle everything for you. - -The following command can be used to upload files to Cloudflare R2: - -```bash -# Make sure to set the AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY environment variables -fluentci run --wasm r2-sync upload --endpoint-url https://$ACCOUNT_ID.r2.cloudflarestorage.com s3://$BUCKET_NAME -``` diff --git a/docs/cookbook/upload-to-r2.mdx b/docs/cookbook/upload-to-r2.mdx new file mode 100644 index 0000000..3630a26 --- /dev/null +++ b/docs/cookbook/upload-to-r2.mdx @@ -0,0 +1,156 @@ +--- +sidebar_position: 27 +--- + +# Upload files to Cloudflare R2 + +This page explains how to upload files to Cloudflare R2 with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `Cloudflare R2`. In addition: + +- Have your project ready, including the files you want to upload. +- Have a Cloudflare account. +- Have a Cloudflare R2 Bucket. +- Have a Cloudflare R2 Access Key. +- Have a Cloudflare R2 Secret Key. + +## Using the R2 Plugin + +You can use FluentCI to upload files to Cloudflare R2 using the [r2-sync plugin](https://github.com/tsirysndr/daggerverse/tree/main/r2-sync), no need to install AWS CLI on your machine, FluentCI will handle everything for you. + +The following command can be used to upload files to Cloudflare R2: + +```bash +# Make sure to set the AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY environment variables +fluentci run --wasm r2-sync upload --endpoint-url https://$ACCOUNT_ID.r2.cloudflarestorage.com s3://$BUCKET_NAME +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to upload files to Cloudflare R2: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: upload + run: fluentci run --wasm r2-sync upload --endpoint-url https://$ACCOUNT_ID.r2.cloudflarestorage.com s3://$BUCKET_NAME + env: + AWS_ACCESS_KEY_ID: \${{ secrets.AWS_ACCESS_KEY_ID }} + AWS_SECRET_ACCESS_KEY: \${{ secrets.AWS_SECRET_ACCESS_KEY }} + ACCOUNT_ID: \${{ secrets.ACCOUNT_ID }} + BUCKET_NAME: \${{ secrets.BUCKET_NAME }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + AWS_ACCESS_KEY_ID: $AWS_ACCESS_KEY_ID + AWS_SECRET_ACCESS_KEY: $AWS_SECRET_ACCESS_KEY + ACCOUNT_ID: $ACCOUNT_ID + BUCKET_NAME: $BUCKET_NAME +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +upload: + extends: .fluentci + script: + - fluentci run --wasm r2-sync upload --endpoint-url https://$ACCOUNT_ID.r2.cloudflarestorage.com s3://$BUCKET_NAME +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm r2-sync upload --endpoint-url https://$ACCOUNT_ID.r2.cloudflarestorage.com s3://$BUCKET_NAME + name: upload + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm r2-sync upload --endpoint-url https://$ACCOUNT_ID.r2.cloudflarestorage.com s3://$BUCKET_NAME + displayName: upload + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm r2-sync upload --endpoint-url https://$ACCOUNT_ID.r2.cloudflarestorage.com s3://$BUCKET_NAME + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/docs/cookbook/upload-to-s3.md b/docs/cookbook/upload-to-s3.md deleted file mode 100644 index 21ecb66..0000000 --- a/docs/cookbook/upload-to-s3.md +++ /dev/null @@ -1,28 +0,0 @@ ---- -sidebar_position: 28 ---- - -# Upload files to AWS S3 - -This page explains how to upload files to AWS S3 with FluentCI. - -## Before you begin - -The instructions on this page assume that you are familiar with `AWS S3`. In addition: - -- Have your project ready, including the files you want to upload. -- Have an AWS account. -- Have an AWS S3 Bucket. -- Have an AWS Access Key. -- Have an AWS Secret Key. - -## Using the S3 Plugin - -You can use FluentCI to upload files to AWS S3 using the [r2-sync plugin](https://github.com/tsirysndr/daggerverse/tree/main/r2-sync), no need to install AWS CLI on your machine, FluentCI will handle everything for you. - -The following command can be used to upload files to `AWS S3`: - -```bash -# Make sure to set the AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY environment variables -fluentci run --wasm r2-sync upload --endpoint-url $ENDPOINT_URL s3://$BUCKET_NAME -``` diff --git a/docs/cookbook/upload-to-s3.mdx b/docs/cookbook/upload-to-s3.mdx new file mode 100644 index 0000000..677bba2 --- /dev/null +++ b/docs/cookbook/upload-to-s3.mdx @@ -0,0 +1,156 @@ +--- +sidebar_position: 28 +--- + +# Upload files to AWS S3 + +This page explains how to upload files to AWS S3 with FluentCI. + +## Before you begin + +The instructions on this page assume that you are familiar with `AWS S3`. In addition: + +- Have your project ready, including the files you want to upload. +- Have an AWS account. +- Have an AWS S3 Bucket. +- Have an AWS Access Key. +- Have an AWS Secret Key. + +## Using the S3 Plugin + +You can use FluentCI to upload files to AWS S3 using the [r2-sync plugin](https://github.com/tsirysndr/daggerverse/tree/main/r2-sync), no need to install AWS CLI on your machine, FluentCI will handle everything for you. + +The following command can be used to upload files to `AWS S3`: + +```bash +# Make sure to set the AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY environment variables +fluentci run --wasm r2-sync upload --endpoint-url $ENDPOINT_URL s3://$BUCKET_NAME +``` + +## CI/CD pipeline integrations + +The following examples show how to integrate FluentCI with popular CI providers to upload files to AWS S3: + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; +import CodeBlock from "@theme/CodeBlock"; + + + + + {`name: ci +on: + push: + branches: + - main +jobs: + tasks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Setup Fluent CI + uses: fluentci-io/setup-fluentci@v5 + - name: upload + run: fluentci run --wasm r2-sync upload --endpoint-url $ENDPOINT_URL s3://$BUCKET_NAME + env: + AWS_ACCESS_KEY_ID: \${{ secrets.AWS_ACCESS_KEY_ID }} + AWS_SECRET_ACCESS_KEY: \${{ secrets.AWS_SECRET_ACCESS_KEY }} + ENDPOINT_URL: \${{ env.ENDPOINT_URL }} + BUCKET_NAME: \${{ env.BUCKET_NAME }} + `} + + + + + {`.docker: + image: denoland/deno:debian-1.42.4 + services: + - docker:\${DOCKER_VERSION}-dind + variables: + DOCKER_HOST: tcp://docker:2376 + DOCKER_TLS_VERIFY: "1" + DOCKER_TLS_CERTDIR: /certs + DOCKER_CERT_PATH: /certs/client + DOCKER_DRIVER: overlay2 + DOCKER_VERSION: 20.10.16 + GITLAB_ACCESS_TOKEN: $GITLAB_ACCESS_TOKEN + AWS_ACCESS_KEY_ID: $AWS_ACCESS_KEY_ID + AWS_SECRET_ACCESS_KEY: $AWS_SECRET_ACCESS_KEY + ENDPOINT_URL: $ENDPOINT_URL + BUCKET_NAME: $BUCKET_NAME +.fluentci: + extends: .docker + before_script: + - apt-get update + - apt-get install -y curl tar gzip ca-certificates openssl git unzip libncursesw6 + - deno install -A -r https://cli.fluentci.io -n fluentci + - fluentci --version + - curl -L https://dl.dagger.io/dagger/install.sh | DAGGER_VERSION=0.12.3 sh + - mv bin/dagger /usr/local/bin + - dagger version +upload: + extends: .fluentci + script: + - fluentci run --wasm r2-sync upload --endpoint-url $ENDPOINT_URL s3://$BUCKET_NAME +`} + + + + + +{`version: 2.1 +jobs: + job: + steps: + - checkout + - run: | + sudo apt-get update && sudo apt-get install -y curl unzip + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + name: Setup FluentCI + - run: fluentci run --wasm r2-sync upload --endpoint-url $ENDPOINT_URL s3://$BUCKET_NAME + name: upload + machine: + image: ubuntu-2004:2023.07.1 +workflows: + fluentci: + jobs: + - job + `} + + + + +{`trigger: + - main +pool: + vmImage: ubuntu-latest +steps: + - script: | + curl -fsSL https://cli.fluentci.io | bash + fluentci --version + echo "##vso[task.prependpath]\${HOME}/.deno/bin + displayName: Setup FluentCI + - script: fluentci run --wasm r2-sync upload --endpoint-url $ENDPOINT_URL s3://$BUCKET_NAME + displayName: upload + `} + + + + +{`version: 0.2 +phases: + install: + commands: + - curl -fsSL https://cli.fluentci.io | bash + - fluentci --version + build: + commands: + - fluentci run --wasm r2-sync upload --endpoint-url $ENDPOINT_URL s3://$BUCKET_NAME + post_build: + commands: + - echo Build completed on \`date\` + `} + + + diff --git a/src/css/custom.css b/src/css/custom.css index 3812b81..0eaddcc 100644 --- a/src/css/custom.css +++ b/src/css/custom.css @@ -143,3 +143,7 @@ pre { .menu__link--active:not(.menu__link--sublist) { background-color: #1d503f78; } + +.token.atrule, .token.attr-value, .token.keyword { + color: #14ffeb; +} \ No newline at end of file diff --git a/src/theme/prism-include-languages.js b/src/theme/prism-include-languages.js new file mode 100644 index 0000000..0f88830 --- /dev/null +++ b/src/theme/prism-include-languages.js @@ -0,0 +1,23 @@ +import siteConfig from '@generated/docusaurus.config'; +export default function prismIncludeLanguages(PrismObject) { + const { + themeConfig: {prism}, + } = siteConfig; + const {additionalLanguages} = prism; + // Prism components work on the Prism instance on the window, while prism- + // react-renderer uses its own Prism instance. We temporarily mount the + // instance onto window, import components to enhance it, then remove it to + // avoid polluting global namespace. + // You can mutate PrismObject: registering plugins, deleting languages... As + // long as you don't re-assign it + globalThis.Prism = PrismObject; + additionalLanguages.forEach((lang) => { + if (lang === 'php') { + // eslint-disable-next-line global-require + require('prismjs/components/prism-markup-templating.js'); + } + // eslint-disable-next-line global-require, import/no-dynamic-require + require(`prismjs/components/prism-${lang}`); + }); + delete globalThis.Prism; +}