-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add
require_online_players
and require_online_players_blacklist
f…
…or scheduled backup cherry-picked changes from 6bb21da added mermaid support to the doc resolved #13
- Loading branch information
1 parent
35b5e11
commit 9472ff4
Showing
11 changed files
with
2,145 additions
and
19 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
mkdocs | ||
mkdocs-material | ||
mkdocs-mermaid2-plugin | ||
mkdocs-static-i18n[material] | ||
pymdown-extensions |
This file contains 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
This file contains 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
This file was deleted.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import re | ||
from typing import Optional, List | ||
|
||
from prime_backup.config.config_common import CrontabJobSetting | ||
from prime_backup.types.units import Duration | ||
|
||
|
||
class ScheduledBackupConfig(CrontabJobSetting): | ||
enabled: bool = False | ||
interval: Optional[Duration] = Duration('12h') | ||
crontab: Optional[str] = None | ||
jitter: Duration = Duration('10s') | ||
|
||
reset_timer_on_backup: bool = True | ||
require_online_players: bool = False | ||
require_online_players_blacklist: List[re.Pattern] = [] | ||
|
||
def on_deserialization(self, **kwargs): | ||
# recompile patterns with re.IGNORECASE | ||
self.require_online_players_blacklist = [ | ||
re.compile(p.pattern, re.IGNORECASE) | ||
for p in self.require_online_players_blacklist | ||
] |
This file contains 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
This file contains 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
Oops, something went wrong.