Allow skipping forks (and a dry-run bonus) #20

Closed
opened 2025-07-08 08:33:17 -04:00 by AtHeartEngineer · 0 comments

Originally created by @jdevera on 7/19/2024

This PR brings the following changes:

  • Mainly, by setting the SKIP_FORKS env var, forks will not be mirrored, regardless of the other configurations.
  • A new option DRY_RUN is also introduced. When set, the mirror creation action is skipped but logged. This makes it easier to check the setup before anything is written to Gitea.
  • All existing and new environment flags can be enabled by setting them to true or 1
  • The current settings are logged in every run, but tokens are masked so they are not revealed in logs.
  • Internal: All flags are parsed to booleans early
  • Strong suggestion: use unless-stopped instead of always for the restart policy in the docker-compose example.

Closes: #16

*Originally created by @jdevera on 7/19/2024* This PR brings the following changes: * Mainly, by setting the `SKIP_FORKS` env var, forks will not be mirrored, regardless of the other configurations. * A new option `DRY_RUN` is also introduced. When set, the mirror creation action is skipped but logged. This makes it easier to check the setup before anything is written to Gitea. * All existing and new environment flags can be enabled by setting them to `true` or `1` * The current settings are logged in every run, but tokens are masked so they are not revealed in logs. * Internal: All flags are parsed to booleans early * Strong suggestion: use `unless-stopped` instead of `always` for the restart policy in the docker-compose example. Closes: #16
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/mirror-to-gitea#20