Network Synchronization #2923
This file contains hidden or 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: Network Synchronization | |
on: | |
schedule: | |
- cron: '00 06,18 * * *' | |
workflow_dispatch: | |
inputs: | |
synchronization-level: | |
description: 'Desired % synchronization level. Between 0 and 1.' | |
required: false | |
default: 1 | |
type: number | |
jobs: | |
sync_and_cache: | |
strategy: | |
matrix: | |
network: [ preview ] | |
ogmios_version: [ v6.11.0 ] | |
cardano_node_version: [ 10.1.4 ] | |
runs-on: ubuntu-latest | |
steps: | |
- name: 📥 Checkout repository | |
uses: actions/[email protected] | |
- name: ⌚ Get Date/Time | |
id: date-time | |
shell: bash | |
run: | | |
echo "timestamp=$(/bin/date -u '+%Y%m%d-%H%M%S')" >> $GITHUB_OUTPUT | |
- name: 💾 Cache cardano-node DB | |
id: cache | |
uses: actions/cache@v4 | |
with: | |
path: ${{ runner.temp }}/db-${{ matrix.network }} | |
key: cardano-node-ogmios-${{ matrix.network }}-${{ steps.date-time.outputs.timestamp }} | |
restore-keys: | | |
cardano-node-ogmios-${{ matrix.network }}- | |
- name: ⟲ Sync Node | |
uses: CardanoSolutions/[email protected] | |
with: | |
db-dir: ${{ runner.temp }}/db-${{ matrix.network }} | |
network: ${{ matrix.network }} | |
version: ${{ matrix.ogmios_version }}_${{ matrix.cardano_node_version }} | |
synchronization-level: ${{ inputs.synchronization-level || 1 }} |