Просмотр исходного кода

Create porter_preview_env.yml file (#2661)

Co-authored-by: porter-deployment-app[bot] <87230664+porter-deployment-app[bot]@users.noreply.github.com>
porter-deployment-app[bot] 3 лет назад
Родитель
Сommit
6098bcb6cd
1 измененных файлов с 45 добавлено и 0 удалено
  1. 45 0
      .github/workflows/porter_preview_env.yml

+ 45 - 0
.github/workflows/porter_preview_env.yml

@@ -0,0 +1,45 @@
+"on":
+  workflow_dispatch:
+    inputs:
+      pr_branch_from:
+        description: Pull request head branch
+        required: true
+        type: string
+      pr_branch_into:
+        description: Pull request base branch
+        required: true
+        type: string
+      pr_number:
+        description: Pull request number
+        required: true
+        type: string
+      pr_title:
+        description: Pull request title
+        required: true
+        type: string
+name: Porter Preview Environment
+jobs:
+  porter-preview:
+    runs-on: ubuntu-latest
+    steps:
+    - name: Checkout code
+      uses: actions/checkout@v2.3.4
+    - name: Create Porter preview env
+      timeout-minutes: 30
+      uses: porter-dev/porter-preview-action@v0.2.1
+      with:
+        action_id: ${{ github.run_id }}
+        cluster: "2481"
+        host: https://dashboard.getporter.dev
+        installation_id: "18533943"
+        namespace: pr-${{ github.event.inputs.pr_number }}-porter
+        pr_branch_from: ${{ github.event.inputs.pr_branch_from }}
+        pr_branch_into: ${{ github.event.inputs.pr_branch_into }}
+        pr_id: ${{ github.event.inputs.pr_number }}
+        pr_name: ${{ github.event.inputs.pr_title }}
+        project: "6680"
+        repo_name: porter
+        repo_owner: porter-dev
+        token: ${{ secrets.PORTER_PREVIEW_6680_2481 }}
+    concurrency:
+      group: ${{ github.workflow }}-${{ github.event.inputs.pr_number }}