Skip to content

[feature] Still maintain state even if repository can't be reached #876

@lukasgierth

Description

@lukasgierth

Description

Add a feature flag (through env variable) that enables doco-cd trying to maintain its last known state even if remote repo cant be reached for whatever reason.

Use Case

My problem/use-case is as follows:

My forgejo instance with the repo is on a debian docker host where also doco-cd manages my stacks (including traefik in front of the forgejo instance)

Szenario:

  • traefik is down (because stack not running for some reason), forgejo can't be reached anymore
  • doco-cd does polling, can't reach forgejo and stops doing anything at all
  • But doco-cd already has the repo from it's last polling (it just does not know if anything changed)

My feature wish would be:

  • Introduce a feature for doco-cd (which could be enabled by an env variable) which then still tries to maintain the status it knows when it cant reach the repository/repositories

Meaning: doco-cd has an older commit checked out and has information from that point in time which deployments should be running. So even it can't reach the remote repository to get the last state, it should still get to the status last known to it.

In that case it would see that the traefik compose is down and bring it back up. Then at the next polling it can reach forgejo again and everything is fine.

Additional Information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions