Skip to content

Commit

Permalink
fix new snapshot path extraction
Browse files Browse the repository at this point in the history
  • Loading branch information
sudo-shashank committed May 8, 2024
1 parent 333ab13 commit 94fe2be
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ansible/archival-snapshots/resources/main.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ while ((LATEST_EPOCH - CURRENT_EPOCH > 30000)); do

# Export full snapshot to generate lite and diff snapshots
$FOREST_CLI snapshot export --tipset "$NEW_EPOCH" --depth 30000 > export.log
NEW_SNAPSHOT=$(grep forest export.log | awk -F'[:]' '{print $1}')
NEW_SNAPSHOT=$(grep -a forest export.log | awk -F'[:]' '{print $1}' | tail -1)
echo "New Snapshot Downloaded: $NEW_SNAPSHOT"

# Generate and upload lite snapshot
if [ ! -f "$LITE_SNAPSHOT_DIR/$NEW_SNAPSHOT" ]; then
Expand Down

0 comments on commit 94fe2be

Please sign in to comment.