fix: force .mo. reload in reload
This commit is contained in:
parent
08972266db
commit
4b8ea49c0c
1 changed files with 3 additions and 1 deletions
|
|
@ -1,5 +1,6 @@
|
|||
import logging
|
||||
from datetime import datetime
|
||||
from pathlib import Path
|
||||
from typing import Annotated
|
||||
|
||||
from bubus import EventBus
|
||||
|
|
@ -24,11 +25,12 @@ class ReloadService:
|
|||
async def on_reload(self, event: ReloadEvent):
|
||||
logger.info(f"Received ReloadEvent: {event.service}")
|
||||
head = self._git.get_head()
|
||||
mos = Path('files/forge').glob('*.mo.*')
|
||||
await self._bus.dispatch(WoodpeckerEvent(
|
||||
_id=-1,
|
||||
commit=head.sha,
|
||||
ref=head.branch,
|
||||
message=f"Manual reload of {event.service}",
|
||||
started=int(datetime.now().timestamp()),
|
||||
files=[f"compose/{event.service}/docker-compose.yml"]
|
||||
files=[f"compose/{event.service}/docker-compose.yml"] + [str(pp) for pp in list(mos)]
|
||||
))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue