diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 967f4da5e..40c67d874 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -109,14 +109,14 @@ jobs: ', github.ref) || startsWith(github.ref, 'refs/tags/v') steps: - - uses: actions/checkout@v4 - - name: Set env for develop branch - if: endsWith(github.ref, '/develop') || endsWith(github.ref, '-beta') - run: | - echo "HOST=${{ secrets.DEV_HOST }}" >> $GITHUB_ENV - echo "USERNAME=${{ secrets.DEV_USER }}" >> $GITHUB_ENV - echo "SITE_URL=staging-ddw.devinit.org" >> $GITHUB_ENV - echo "SPOTLIGHTS_URL=staging-api.devinit.org" >> $GITHUB_ENV + # - uses: actions/checkout@v4 + # - name: Set env for develop branch + # if: endsWith(github.ref, '/develop') || endsWith(github.ref, '-beta') + # run: | + # echo "HOST=${{ secrets.DEV_HOST }}" >> $GITHUB_ENV + # echo "USERNAME=${{ secrets.DEV_USER }}" >> $GITHUB_ENV + # echo "SITE_URL=staging-ddw.devinit.org" >> $GITHUB_ENV + # echo "SPOTLIGHTS_URL=staging-api.devinit.org" >> $GITHUB_ENV - name: Set env for release branch if: startsWith(github.ref, 'refs/tags/v') && !endsWith(github.ref, '-beta') @@ -131,16 +131,16 @@ jobs: id: get_version run: echo VERSION=$(echo $GITHUB_REF | cut -d / -f 3) >> $GITHUB_OUTPUT - - name: copy deploy scripts to dev server - if: endsWith(github.ref, '/develop') || endsWith(github.ref, '-beta') - uses: appleboy/scp-action@v0.1.7 - with: - host: ${{ env.HOST }} - username: ${{ env.USERNAME }} - port: ${{ secrets.PORT }} - key: ${{ secrets.KEY }} - source: "deploy_script.sh,deploy.sh" - target: "." + # - name: copy deploy scripts to dev server + # if: endsWith(github.ref, '/develop') || endsWith(github.ref, '-beta') + # uses: appleboy/scp-action@v0.1.7 + # with: + # host: ${{ env.HOST }} + # username: ${{ env.USERNAME }} + # port: ${{ secrets.PORT }} + # key: ${{ secrets.KEY }} + # source: "deploy_script.sh,deploy.sh" + # target: "." - name: copy deploy script to production server if: startsWith(github.ref, 'refs/tags/v') && !endsWith(github.ref, '-beta') @@ -153,34 +153,34 @@ jobs: source: "deploy.sh" target: "." - - name: ssh into remote dev server for develop branch - if: endsWith(github.ref, '/develop') - uses: appleboy/ssh-action@v1.0.3 - with: - host: ${{ env.HOST }} - username: ${{ env.USERNAME }} - key: ${{ secrets.KEY }} - port: ${{ secrets.PORT }} - command_timeout: 30m - script: | - chmod 700 "deploy_script.sh" - ./deploy_script.sh - - - name: ssh into remote dev server for beta tag - if: endsWith(github.ref, '-beta') - uses: appleboy/ssh-action@v1.0.3 - with: - host: ${{ env.HOST }} - username: ${{ env.USERNAME }} - key: ${{ secrets.KEY }} - port: ${{ secrets.PORT }} - command_timeout: 30m - script: | - version=$(echo ${{ steps.get_version.outputs.VERSION }} | cut -c 2-) - export SITE_URL=${{ env.SITE_URL }} - export SPOTLIGHTS_URL=${{ env.SPOTLIGHTS_URL }} - chmod 700 "deploy.sh" - ./deploy.sh $version + # - name: ssh into remote dev server for develop branch + # if: endsWith(github.ref, '/develop') + # uses: appleboy/ssh-action@v1.0.3 + # with: + # host: ${{ env.HOST }} + # username: ${{ env.USERNAME }} + # key: ${{ secrets.KEY }} + # port: ${{ secrets.PORT }} + # command_timeout: 30m + # script: | + # chmod 700 "deploy_script.sh" + # ./deploy_script.sh + + # - name: ssh into remote dev server for beta tag + # if: endsWith(github.ref, '-beta') + # uses: appleboy/ssh-action@v1.0.3 + # with: + # host: ${{ env.HOST }} + # username: ${{ env.USERNAME }} + # key: ${{ secrets.KEY }} + # port: ${{ secrets.PORT }} + # command_timeout: 30m + # script: | + # version=$(echo ${{ steps.get_version.outputs.VERSION }} | cut -c 2-) + # export SITE_URL=${{ env.SITE_URL }} + # export SPOTLIGHTS_URL=${{ env.SPOTLIGHTS_URL }} + # chmod 700 "deploy.sh" + # ./deploy.sh $version - name: ssh into remote production server if: startsWith(github.ref, 'refs/tags/v') && !endsWith(github.ref, '-beta') @@ -199,6 +199,7 @@ jobs: ./deploy.sh $version - name: Build JS + if: startsWith(github.ref, 'refs/tags/v') && !endsWith(github.ref, '-beta') uses: appleboy/ssh-action@v1.0.3 with: host: ${{ env.HOST }}