Merge pull request #153 from LerianStudio/develop #6
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
name: Update midaz-full | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
update-submodule: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Import GPG key | |
uses: crazy-max/ghaction-import-gpg@v6 | |
id: import_gpg | |
with: | |
gpg_private_key: ${{ secrets.LERIAN_CI_CD_USER_GPG_KEY }} | |
passphrase: ${{ secrets.LERIAN_CI_CD_USER_GPG_KEY_PASSWORD }} | |
git_committer_name: ${{ secrets.LERIAN_CI_CD_USER_NAME }} | |
git_committer_email: ${{ secrets.LERIAN_CI_CD_USER_EMAIL }} | |
git_config_global: true | |
git_user_signingkey: true | |
git_commit_gpgsign: true | |
- name: Pull midaz-full and submodules | |
uses: actions/checkout@v4 | |
with: | |
repository: LerianStudio/midaz-full | |
ref: main | |
path: midaz-full | |
submodules: recursive | |
token: ${{ secrets.MANAGE_TOKEN }} | |
- name: Push midaz-full and midaz submodule | |
env: | |
GPG_FINGERPRINT: ${{ steps.import_gpg.outputs.fingerprint }} | |
GITHUB_TOKEN: ${{ secrets.MANAGE_TOKEN }} | |
GIT_AUTHOR_NAME: ${{ secrets.LERIAN_CI_CD_USER_NAME }} | |
GIT_AUTHOR_EMAIL: ${{ secrets.LERIAN_CI_CD_USER_EMAIL }} | |
GIT_COMMITTER_NAME: ${{ secrets.LERIAN_CI_CD_USER_NAME }} | |
GIT_COMMITTER_EMAIL: ${{ secrets.LERIAN_CI_CD_USER_EMAIL }} | |
run: | | |
cd midaz-full | |
cd midaz-console | |
git checkout main | |
git pull origin main | |
cd .. | |
git add midaz-console | |
git commit -S -m "Updating the submodule 'midaz-console' to the latest version" | |
git push origin main |