Skip to content

Commit

Permalink
Merge pull request 'Add triggers for test OCI docker' (#84) from feat…
Browse files Browse the repository at this point in the history
…ure/oci-install-docker into develop

Reviewed-on: https://git.onlyoffice.com/ONLYOFFICE/DocSpace-buildtools/pulls/84
Reviewed-by: Evgeniy Antonyuk <[email protected]>
  • Loading branch information
evgeniy-antonyuk committed Nov 21, 2024
2 parents f32d607 + 6c2bfd9 commit e578bd1
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 1 deletion.
20 changes: 19 additions & 1 deletion .github/workflows/ci-oci-docker-install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,39 @@ on:
paths:
- '.github/workflows/ci-oci-docker-install.yml'
- 'install/OneClickInstall/install-Docker.sh'
push:
branches:
- 'hotfix/**'
- 'release/**'
- 'develop'
workflow_dispatch:
inputs:
offline:
description: 'Publish 4testing offline archive'
required: true
default: false
type: boolean
repository_dispatch:
types:
- oci-docker-install-trigger

jobs:
Install-OneClickInstall-Docker:
runs-on: ubuntu-22.04
steps:
- name: Determine Branch Name
run: |
BRANCH_NAME=$([ "${{ github.event_name }}" = "pull_request" ] && echo "${{ github.event.pull_request.head.ref }}" || echo "${GITHUB_REF#refs/heads/}")
case "${{ github.event_name }}" in
"pull_request")
BRANCH_NAME="${{ github.event.pull_request.head.ref }}"
;;
"repository_dispatch")
BRANCH_NAME="${{ github.event.client_payload.branch }}"
;;
*)
BRANCH_NAME="${GITHUB_REF#refs/heads/}"
;;
esac
echo "BRANCH_NAME=${BRANCH_NAME:-master}" >> $GITHUB_ENV
- name: Free Disk Space
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/config-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ on:
paths:
- 'config/**'
- 'install/docker/Dockerfile.app'
- 'install/docker/*entrypoint*.*'
workflow_dispatch:

jobs:
Expand Down
11 changes: 11 additions & 0 deletions .github/workflows/main-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,3 +88,14 @@ jobs:
-f branch=${{ matrix.branch }} \
-f version=${VERSION}
fi
- name: Dispatch Action
run: |
echo "OCI docker test on branch ${{ matrix.branch }}"
curl \
-X POST \
-u "${{ secrets.USERNAME}}:${{secrets.TOKEN}}" \
-H "Accept: application/vnd.github.v3+json" \
https://api.github.com/repos/ONLYOFFICE/DocSpace-buildtools/dispatches \
-d '{"event_type": "oci-docker-install-trigger", "client_payload": {"branch": "'"${{ matrix.branch }}"'"}}'

0 comments on commit e578bd1

Please sign in to comment.