Closed NickGraham101 closed 2 years ago
Sharing the problem we are facing here:
Error: unexpected error encountered: HttpError: Validation Failed: {"resource":"DeploymentStatus","code":"custom","message":"This deployment has reached the maximum number of statuses."} - see logs for more information
I believe this is due to how override works, it is fetching for all deployments of a given environment and updating its status:
: found 100 existing deployments for env
: setting deployment (***************) state to "inactive"
..... (100 more lines)
I think the solution @NickGraham101 mentioned would work for our use case also.
what is the solution, could you please share? as I m also facing similar issue
We are hitting this This deployment has reached the maximum number of statuses.
error too. Had to disable this action for now.
Thanks for the suggestion @NickGraham101 , I was hitting the same issues and disabling override on my finish actions appears to have done the trick. You saved my a whole pile of confusion, appreciate it.
@nilampatel-engineer here's what my solution looked like in the end, i hope this clarifies things for you.
- name: update deployment status
uses: bobheadxi/deployments@main
if: always()
with:
step: finish
token: ${{ secrets.GITHUB_TOKEN }}
status: ${{ job.status }}
deployment_id: ${{ steps.deployment.outputs.deployment_id }}
env: ${{ steps.classify.outputs.environment_key }}
env_url: "https://${{ steps.GET_TF_OUTPUT.outputs.DOMAIN }}"
desc: "Pull request env update"
override: false
Just to be clear the fix was adding override: false
.
I'm also seeing this issue. override: false
stops the errors but all previous deployments remain active. It seems as though the action tries to mark all past deployments inactive, including the many that are already inactive.
Hey everyone, unfortunately, I haven't been able to take a look at this and probably won't have the bandwidth to actively maintain this project for the time being. If someone finds a good way forward I would appreciate a PR!
If anyone is open to helping me maintain this project I'd be super grateful and happy to chat, please reach out to me via twitter, email, or https://github.com/bobheadxi/deployments/discussions/103! 🙏
fixed with #104
After upgrading from v0.6.2 to v1 we encountered a rate limiting issue with the default settings of, I've discussed this further here.
We attempted to resolve this by changing
override
tofalse
and relying on the default setting oftrue
forauto_inactive
however this was only partially successful. We no longer get rate limited because there are no API calls being made to update the inactive deployments. However the status of the previous deployments are not getting updated, I believe this is because all deployments are now created withtransient_environment: true
.As per the docs:
I created a simple pipeline here which shows the multiple active deployments here.
Is it possible to make
transient_environment
a configurable value again?