-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3878 from makeplane/preview
release: v0.16-dev
- Loading branch information
Showing
484 changed files
with
13,042 additions
and
9,390 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,6 +23,10 @@ jobs: | |
gh_buildx_version: ${{ steps.set_env_variables.outputs.BUILDX_VERSION }} | ||
gh_buildx_platforms: ${{ steps.set_env_variables.outputs.BUILDX_PLATFORMS }} | ||
gh_buildx_endpoint: ${{ steps.set_env_variables.outputs.BUILDX_ENDPOINT }} | ||
build_frontend: ${{ steps.changed_files.outputs.frontend_any_changed }} | ||
build_space: ${{ steps.changed_files.outputs.space_any_changed }} | ||
build_backend: ${{ steps.changed_files.outputs.backend_any_changed }} | ||
build_proxy: ${{ steps.changed_files.outputs.proxy_any_changed }} | ||
|
||
steps: | ||
- id: set_env_variables | ||
|
@@ -41,7 +45,36 @@ jobs: | |
fi | ||
echo "TARGET_BRANCH=${{ env.TARGET_BRANCH }}" >> $GITHUB_OUTPUT | ||
- id: checkout_files | ||
name: Checkout Files | ||
uses: actions/checkout@v4 | ||
|
||
- name: Get changed files | ||
id: changed_files | ||
uses: tj-actions/changed-files@v42 | ||
with: | ||
files_yaml: | | ||
frontend: | ||
- web/** | ||
- packages/** | ||
- 'package.json' | ||
- 'yarn.lock' | ||
- 'tsconfig.json' | ||
- 'turbo.json' | ||
space: | ||
- space/** | ||
- packages/** | ||
- 'package.json' | ||
- 'yarn.lock' | ||
- 'tsconfig.json' | ||
- 'turbo.json' | ||
backend: | ||
- apiserver/** | ||
proxy: | ||
- nginx/** | ||
branch_build_push_frontend: | ||
if: ${{ needs.branch_build_setup.outputs.build_frontend == 'true' || github.event_name == 'release' || needs.branch_build_setup.outputs.gh_branch_name == 'master' }} | ||
runs-on: ubuntu-20.04 | ||
needs: [branch_build_setup] | ||
env: | ||
|
@@ -55,9 +88,9 @@ jobs: | |
- name: Set Frontend Docker Tag | ||
run: | | ||
if [ "${{ github.event_name }}" == "release" ]; then | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-frontend:latest,${{ secrets.DOCKERHUB_USERNAME }}/plane-frontend:${{ github.event.release.tag_name }} | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-frontend:stable,${{ secrets.DOCKERHUB_USERNAME }}/plane-frontend:${{ github.event.release.tag_name }} | ||
elif [ "${{ env.TARGET_BRANCH }}" == "master" ]; then | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-frontend:stable | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-frontend:latest | ||
else | ||
TAG=${{ env.FRONTEND_TAG }} | ||
fi | ||
|
@@ -77,7 +110,7 @@ jobs: | |
endpoint: ${{ env.BUILDX_ENDPOINT }} | ||
|
||
- name: Check out the repo | ||
uses: actions/checkout@v4.1.1 | ||
uses: actions/checkout@v4 | ||
|
||
- name: Build and Push Frontend to Docker Container Registry | ||
uses: docker/[email protected] | ||
|
@@ -93,6 +126,7 @@ jobs: | |
DOCKER_PASSWORD: ${{ secrets.DOCKERHUB_TOKEN }} | ||
|
||
branch_build_push_space: | ||
if: ${{ needs.branch_build_setup.outputs.build_space == 'true' || github.event_name == 'release' || needs.branch_build_setup.outputs.gh_branch_name == 'master' }} | ||
runs-on: ubuntu-20.04 | ||
needs: [branch_build_setup] | ||
env: | ||
|
@@ -106,9 +140,9 @@ jobs: | |
- name: Set Space Docker Tag | ||
run: | | ||
if [ "${{ github.event_name }}" == "release" ]; then | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-space:latest,${{ secrets.DOCKERHUB_USERNAME }}/plane-space:${{ github.event.release.tag_name }} | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-space:stable,${{ secrets.DOCKERHUB_USERNAME }}/plane-space:${{ github.event.release.tag_name }} | ||
elif [ "${{ env.TARGET_BRANCH }}" == "master" ]; then | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-space:stable | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-space:latest | ||
else | ||
TAG=${{ env.SPACE_TAG }} | ||
fi | ||
|
@@ -128,7 +162,7 @@ jobs: | |
endpoint: ${{ env.BUILDX_ENDPOINT }} | ||
|
||
- name: Check out the repo | ||
uses: actions/checkout@v4.1.1 | ||
uses: actions/checkout@v4 | ||
|
||
- name: Build and Push Space to Docker Hub | ||
uses: docker/[email protected] | ||
|
@@ -144,6 +178,7 @@ jobs: | |
DOCKER_PASSWORD: ${{ secrets.DOCKERHUB_TOKEN }} | ||
|
||
branch_build_push_backend: | ||
if: ${{ needs.branch_build_setup.outputs.build_backend == 'true' || github.event_name == 'release' || needs.branch_build_setup.outputs.gh_branch_name == 'master' }} | ||
runs-on: ubuntu-20.04 | ||
needs: [branch_build_setup] | ||
env: | ||
|
@@ -157,9 +192,9 @@ jobs: | |
- name: Set Backend Docker Tag | ||
run: | | ||
if [ "${{ github.event_name }}" == "release" ]; then | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-backend:latest,${{ secrets.DOCKERHUB_USERNAME }}/plane-backend:${{ github.event.release.tag_name }} | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-backend:stable,${{ secrets.DOCKERHUB_USERNAME }}/plane-backend:${{ github.event.release.tag_name }} | ||
elif [ "${{ env.TARGET_BRANCH }}" == "master" ]; then | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-backend:stable | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-backend:latest | ||
else | ||
TAG=${{ env.BACKEND_TAG }} | ||
fi | ||
|
@@ -179,7 +214,7 @@ jobs: | |
endpoint: ${{ env.BUILDX_ENDPOINT }} | ||
|
||
- name: Check out the repo | ||
uses: actions/checkout@v4.1.1 | ||
uses: actions/checkout@v4 | ||
|
||
- name: Build and Push Backend to Docker Hub | ||
uses: docker/[email protected] | ||
|
@@ -194,8 +229,8 @@ jobs: | |
DOCKER_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }} | ||
DOCKER_PASSWORD: ${{ secrets.DOCKERHUB_TOKEN }} | ||
|
||
|
||
branch_build_push_proxy: | ||
if: ${{ needs.branch_build_setup.outputs.build_proxy == 'true' || github.event_name == 'release' || needs.branch_build_setup.outputs.gh_branch_name == 'master' }} | ||
runs-on: ubuntu-20.04 | ||
needs: [branch_build_setup] | ||
env: | ||
|
@@ -209,9 +244,9 @@ jobs: | |
- name: Set Proxy Docker Tag | ||
run: | | ||
if [ "${{ github.event_name }}" == "release" ]; then | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-proxy:latest,${{ secrets.DOCKERHUB_USERNAME }}/plane-proxy:${{ github.event.release.tag_name }} | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-proxy:stable,${{ secrets.DOCKERHUB_USERNAME }}/plane-proxy:${{ github.event.release.tag_name }} | ||
elif [ "${{ env.TARGET_BRANCH }}" == "master" ]; then | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-proxy:stable | ||
TAG=${{ secrets.DOCKERHUB_USERNAME }}/plane-proxy:latest | ||
else | ||
TAG=${{ env.PROXY_TAG }} | ||
fi | ||
|
@@ -231,7 +266,7 @@ jobs: | |
endpoint: ${{ env.BUILDX_ENDPOINT }} | ||
|
||
- name: Check out the repo | ||
uses: actions/checkout@v4.1.1 | ||
uses: actions/checkout@v4 | ||
|
||
- name: Build and Push Plane-Proxy to Docker Hub | ||
uses: docker/[email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ name: Create Sync Action | |
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
push: | ||
branches: | ||
- preview | ||
|
||
|
@@ -17,7 +17,7 @@ jobs: | |
contents: read | ||
steps: | ||
- name: Checkout Code | ||
uses: actions/[email protected] | ||
uses: actions/[email protected] | ||
with: | ||
persist-credentials: false | ||
fetch-depth: 0 | ||
|
@@ -31,14 +31,25 @@ jobs: | |
sudo apt update | ||
sudo apt install gh -y | ||
- name: Push Changes to Target Repo | ||
- name: Push Changes to Target Repo A | ||
env: | ||
GH_TOKEN: ${{ secrets.ACCESS_TOKEN }} | ||
run: | | ||
TARGET_REPO="${{ secrets.SYNC_TARGET_REPO_NAME }}" | ||
TARGET_BRANCH="${{ secrets.SYNC_TARGET_BRANCH_NAME }}" | ||
TARGET_REPO="${{ secrets.TARGET_REPO_A }}" | ||
TARGET_BRANCH="${{ secrets.TARGET_REPO_A_BRANCH_NAME }}" | ||
SOURCE_BRANCH="${{ env.SOURCE_BRANCH_NAME }}" | ||
git checkout $SOURCE_BRANCH | ||
git remote add target-origin "https://[email protected]/$TARGET_REPO.git" | ||
git push target-origin $SOURCE_BRANCH:$TARGET_BRANCH | ||
git remote add target-origin-a "https://[email protected]/$TARGET_REPO.git" | ||
git push target-origin-a $SOURCE_BRANCH:$TARGET_BRANCH | ||
- name: Push Changes to Target Repo B | ||
env: | ||
GH_TOKEN: ${{ secrets.ACCESS_TOKEN }} | ||
run: | | ||
TARGET_REPO="${{ secrets.TARGET_REPO_B }}" | ||
TARGET_BRANCH="${{ secrets.TARGET_REPO_B_BRANCH_NAME }}" | ||
SOURCE_BRANCH="${{ env.SOURCE_BRANCH_NAME }}" | ||
git remote add target-origin-b "https://[email protected]/$TARGET_REPO.git" | ||
git push target-origin-b $SOURCE_BRANCH:$TARGET_BRANCH |
Oops, something went wrong.