mirror of
				https://github.com/XRPLF/rippled.git
				synced 2025-11-04 11:15:56 +00:00 
			
		
		
		
	This change refactors the CI workflows to leverage the new CI Docker images for Debian, Red Hat, and Ubuntu.
		
			
				
	
	
		
			141 lines
		
	
	
		
			5.7 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
			
		
		
	
	
			141 lines
		
	
	
		
			5.7 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
# This workflow runs all workflows to build the dependencies required for the
 | 
						|
# project on various Linux flavors, as well as on MacOS and Windows, on a
 | 
						|
# scheduled basis, on merge into the 'develop', 'release', or 'master' branches,
 | 
						|
# or manually. The missing commits check is only run when the code is merged
 | 
						|
# into the 'develop' or 'release' branches, and the documentation is built when
 | 
						|
# the code is merged into the 'develop' branch.
 | 
						|
name: Trigger
 | 
						|
 | 
						|
on:
 | 
						|
  push:
 | 
						|
    branches:
 | 
						|
      - develop
 | 
						|
      - release
 | 
						|
      - master
 | 
						|
    paths:
 | 
						|
      - '.github/actions/build-deps/**'
 | 
						|
      - '.github/actions/build-test/**'
 | 
						|
      - '.github/scripts/strategy-matrix/**'
 | 
						|
      - '.github/workflows/build-test.yml'
 | 
						|
      - '.github/workflows/check-missing-commits.yml'
 | 
						|
      - '.github/workflows/on-trigger.yml'
 | 
						|
      - '.github/workflows/publish-docs.yml'
 | 
						|
      # Keep the list of paths below in sync with those in `on-pr.yml`.
 | 
						|
      - 'cmake/**'
 | 
						|
      - 'conan/**'
 | 
						|
      - 'external/**'
 | 
						|
      - 'include/**'
 | 
						|
      - 'src/**'
 | 
						|
      - 'tests/**'
 | 
						|
      - '.clang-format'
 | 
						|
      - '.codecov.yml'
 | 
						|
      - '.pre-commit-config.yaml'
 | 
						|
      - 'CMakeLists.txt'
 | 
						|
      - 'conanfile.py'
 | 
						|
  # Run at 06:32 UTC on every day of the week from Monday through Friday. This
 | 
						|
  # will force all dependencies to be rebuilt, which is useful to verify that
 | 
						|
  # all dependencies can be built successfully. Only the dependencies that
 | 
						|
  # are actually missing from the remote will be uploaded.
 | 
						|
  schedule:
 | 
						|
    - cron: '32 6 * * 1-5'
 | 
						|
  # Run when manually triggered via the GitHub UI or API. If `force_upload` is
 | 
						|
  # true, then the dependencies that were missing (`force_rebuild` is false) or
 | 
						|
  # rebuilt (`force_rebuild` is true) will be uploaded, overwriting existing
 | 
						|
  # dependencies if needed.
 | 
						|
  workflow_dispatch:
 | 
						|
    inputs:
 | 
						|
      dependencies_force_build:
 | 
						|
        description: 'Force building of all dependencies.'
 | 
						|
        required: false
 | 
						|
        type: boolean
 | 
						|
        default: false
 | 
						|
      dependencies_force_upload:
 | 
						|
        description: 'Force uploading of all dependencies.'
 | 
						|
        required: false
 | 
						|
        type: boolean
 | 
						|
        default: false
 | 
						|
 | 
						|
concurrency:
 | 
						|
  group: ${{ github.workflow }}-${{ github.ref }}
 | 
						|
  cancel-in-progress: true
 | 
						|
 | 
						|
defaults:
 | 
						|
  run:
 | 
						|
    shell: bash
 | 
						|
 | 
						|
env:
 | 
						|
  CONAN_REMOTE_NAME: xrplf
 | 
						|
  CONAN_REMOTE_URL: https://conan.ripplex.io
 | 
						|
 | 
						|
jobs:
 | 
						|
  check-missing-commits:
 | 
						|
    if: ${{ github.event_name == 'push' && github.ref_type == 'branch' && contains(fromJSON('["develop", "release"]'), github.ref_name) }}
 | 
						|
    uses: ./.github/workflows/check-missing-commits.yml
 | 
						|
 | 
						|
  # This job works around the limitation that GitHub Actions does not support
 | 
						|
  # using environment variables as inputs for reusable workflows. It also sets
 | 
						|
  # outputs that depend on the event that triggered the workflow.
 | 
						|
  generate-outputs:
 | 
						|
    runs-on: ubuntu-latest
 | 
						|
    steps:
 | 
						|
      - name: Check inputs and set outputs
 | 
						|
        id: generate
 | 
						|
        run: |
 | 
						|
          if [[ "${{ github.event_name }}" == 'push' ]]; then
 | 
						|
            echo 'dependencies_force_build=false' | tee "${GITHUB_OUTPUT}"
 | 
						|
            echo 'dependencies_force_upload=false' | tee "${GITHUB_OUTPUT}"
 | 
						|
          elif [[ "${{ github.event_name }}" == 'schedule' ]]; then
 | 
						|
            echo 'dependencies_force_build=true' | tee "${GITHUB_OUTPUT}"
 | 
						|
            echo 'dependencies_force_upload=false' | tee "${GITHUB_OUTPUT}"
 | 
						|
          else
 | 
						|
            echo 'dependencies_force_build=${{ inputs.dependencies_force_build }}' | tee "${GITHUB_OUTPUT}"
 | 
						|
            echo 'dependencies_force_upload=${{ inputs.dependencies_force_upload }}' | tee "${GITHUB_OUTPUT}"
 | 
						|
          fi
 | 
						|
    outputs:
 | 
						|
      conan_remote_name: ${{ env.CONAN_REMOTE_NAME }}
 | 
						|
      conan_remote_url: ${{ env.CONAN_REMOTE_URL }}
 | 
						|
      dependencies_force_build: ${{ steps.generate.outputs.dependencies_force_build }}
 | 
						|
      dependencies_force_upload: ${{ steps.generate.outputs.dependencies_force_upload }}
 | 
						|
 | 
						|
  build-linux:
 | 
						|
    needs: generate-outputs
 | 
						|
    uses: ./.github/workflows/build-test.yml
 | 
						|
    with:
 | 
						|
      conan_remote_name: ${{ needs.generate-outputs.outputs.conan_remote_name }}
 | 
						|
      conan_remote_url: ${{ needs.generate-outputs.outputs.conan_remote_url }}
 | 
						|
      dependencies_force_build: ${{ needs.generate-outputs.outputs.dependencies_force_build }}
 | 
						|
      dependencies_force_upload: ${{ needs.generate-outputs.outputs.dependencies_force_upload }}
 | 
						|
      os: 'linux'
 | 
						|
      strategy_matrix_all: true
 | 
						|
    secrets:
 | 
						|
      conan_remote_username: ${{ secrets.CONAN_REMOTE_USERNAME }}
 | 
						|
      conan_remote_password: ${{ secrets.CONAN_REMOTE_PASSWORD }}
 | 
						|
 | 
						|
  build-macos:
 | 
						|
    needs: generate-outputs
 | 
						|
    uses: ./.github/workflows/build-test.yml
 | 
						|
    with:
 | 
						|
      conan_remote_name: ${{ needs.generate-outputs.outputs.conan_remote_name }}
 | 
						|
      conan_remote_url: ${{ needs.generate-outputs.outputs.conan_remote_url }}
 | 
						|
      dependencies_force_build: ${{ needs.generate-outputs.outputs.dependencies_force_build }}
 | 
						|
      dependencies_force_upload: ${{ needs.generate-outputs.outputs.dependencies_force_upload }}
 | 
						|
      os: 'macos'
 | 
						|
      strategy_matrix_all: true
 | 
						|
    secrets:
 | 
						|
      conan_remote_username: ${{ secrets.CONAN_REMOTE_USERNAME }}
 | 
						|
      conan_remote_password: ${{ secrets.CONAN_REMOTE_PASSWORD }}
 | 
						|
 | 
						|
  build-windows:
 | 
						|
    needs: generate-outputs
 | 
						|
    uses: ./.github/workflows/build-test.yml
 | 
						|
    with:
 | 
						|
      conan_remote_name: ${{ needs.generate-outputs.outputs.conan_remote_name }}
 | 
						|
      conan_remote_url: ${{ needs.generate-outputs.outputs.conan_remote_url }}
 | 
						|
      dependencies_force_build: ${{ needs.generate-outputs.outputs.dependencies_force_build }}
 | 
						|
      dependencies_force_upload: ${{ needs.generate-outputs.outputs.dependencies_force_upload }}
 | 
						|
      os: 'windows'
 | 
						|
      strategy_matrix_all: true
 | 
						|
    secrets:
 | 
						|
      conan_remote_username: ${{ secrets.CONAN_REMOTE_USERNAME }}
 | 
						|
      conan_remote_password: ${{ secrets.CONAN_REMOTE_PASSWORD }}
 |