Skip to content

Commit

Permalink
Merge branch 'master' into fix-ccc-option
Browse files Browse the repository at this point in the history
  • Loading branch information
ashwin1111 authored May 22, 2024
2 parents 8252619 + 57f094a commit ebfe3dc
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/create_release_branch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Create Release Branch
on:
schedule:
# Run every Friday at 11:30 AM UTC (5:00 PM IST)
- cron: '35 09 * * WED'
- cron: '30 11 * * FRI'
jobs:
create-release-branch:
runs-on: ubuntu-latest
Expand Down
54 changes: 54 additions & 0 deletions .github/workflows/hulk_deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: Workflow For Release Branch

on:
push:
branches:
- 'integrations_app_release_*'
jobs:
hulk_deploy:
name: Hulk Deploy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Push to dockerhub
uses: fylein/docker-release-action@master
id: generate-and-push-tag
env:
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
DOCKERHUB_PASSWORD: ${{ secrets.DOCKERHUB_TOKEN }}
IMAGE_NAME: fyle_integrations-app

- name: Install kustomize
run: |
curl -s "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh" | bash
sudo mv kustomize /usr/local/bin/

- name: Clone another repository
uses: actions/checkout@v2
with:
repository: ${{ vars.STAGING_DEPLOY_REPO }}
ref: master
path: ${{ vars.STAGING_DEPLOY_REPO }}
persist-credentials: false
token: ${{ secrets.DEPLOY_GIT_ACCESS_TOKEN }}


- name: Update Image Tag
run: |
NEW_TAG=${{ steps.generate-and-push-tag.outputs.new_tag }}
cd ${{ vars.STAGING_DEPLOY_REPO }}/${{ vars.STAGING_DEPLOY_DIR }}/hulk/integrations
kustomize edit set image docker.io/${{ secrets.DOCKERHUB_USERNAME }}/fyle_integrations-app=docker.io/${{ secrets.DOCKERHUB_USERNAME }}/fyle_integrations-app:$NEW_TAG

- name: Commit and push changes
run: |
NEW_TAG=${{ steps.generate-and-push-tag.outputs.new_tag }}
cd ${{ vars.STAGING_DEPLOY_REPO }}/
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
git add .
git commit -m "Deployed fyle_integrations-app:$NEW_TAG"
git remote set-url origin https://x-access-token:${{ secrets.DEPLOY_GIT_ACCESS_TOKEN }}@github.com/${{ vars.STAGING_DEPLOY_REPO }}
git pull origin master
git push origin master

0 comments on commit ebfe3dc

Please sign in to comment.