Skip to content
This repository has been archived by the owner on Dec 14, 2022. It is now read-only.

Slashdeploy can fail when you use mirrored repositories #182

Open
jherico opened this issue Sep 16, 2021 · 0 comments
Open

Slashdeploy can fail when you use mirrored repositories #182

jherico opened this issue Sep 16, 2021 · 0 comments

Comments

@jherico
Copy link
Contributor

jherico commented Sep 16, 2021

I have a setup where I have a main repo graph-web which has CI jobs that mirror branches main-a and main-b to other repositories of graph-web-a and graph-web-b respectively.

There's an additional CircleCI task that runs on all branches that pushes a docker image to dockerhub tagged with the repo name and the commit hash.

However, I discovered that the github deployments for the mirror jobs were failing. Investigation led me to discover that when an event is received from github about a status change, Slashdeploy looks up ALL pending auto deployments related to corresponding commit hash, regardless of the repository: AutoDeployment.lock.active.where(sha: status.sha).each do |auto_deployment|

This means that when the docker_image CI task on the root repository completes, it triggers the deployment of the mirror-repository branch, which has not yet completed the same job, and therefore hasn't pushed the appropriate tag to dockerhub. The deployment can't find the docker image and fails.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant