From 67fe27c791cb67bbf06c412df9645229f1c1beae Mon Sep 17 00:00:00 2001 From: Marko Frankovic Date: Thu, 27 Mar 2025 13:30:45 +0100 Subject: [PATCH] Clone curh-shemas --- .github/workflows/maven-publish.yml | 35 +++++++++++------------------ 1 file changed, 13 insertions(+), 22 deletions(-) diff --git a/.github/workflows/maven-publish.yml b/.github/workflows/maven-publish.yml index 36147ef..46d841d 100644 --- a/.github/workflows/maven-publish.yml +++ b/.github/workflows/maven-publish.yml @@ -24,6 +24,19 @@ jobs: steps: - uses: actions/checkout@v4 + - name: Checkout tools repo + uses: actions/checkout@v4 + with: + repository: curh-backend/curh-schemas + path: curh-schemas + ref: ${{ github.ref }} + + - name: Unpack curh schemas + run: | + cd curh-schemas/src/main/resources + mkdir -p /opt/rizik + cp -R xsd/ /opt/rizik/ + - name: Set up Maven uses: stCarolas/setup-maven@v5 with: @@ -42,28 +55,6 @@ jobs: java-version: '21' distribution: 'corretto' - - name: Config git and ssh - run: | - git config --global user.email "gitea@pravilanovait.hr" - git config --global user.name "Gitea Actions" - echo -e "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_rsa - chown 600 ~/.ssh/id_rsa - touch ~/.ssh/known_hosts - ssh-keygen -R devops.pravilanovait.hr - ssh-keyscan -t rsa devops.pravilanovait.hr > ~/.ssh/known_hosts - - - name: Clone curh schemas - run: | - git clone git@devops.pravilanovait.hr:curh-backend/curh-schemas.git - cd curh-schemas - git checkout $BRANCH - cd src/main/resources - mkdir -p /opt/rizik - cp -R xsd/ /opt/rizik/ - env: - BRANCH: ${{ github.ref }} - GITHUB_TOKEN: ${{ github.token }} - - name: Set up JDK from ENV if: github.ref != 'refs/heads/feature/T2900-java21' && github.ref != 'refs/heads/feature/T2900-java-21' uses: actions/setup-java@v4