Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: improve stability of build agent packer scripts, remove variables that aren't needed #318

Merged
merged 8 commits into from
Sep 27, 2024

Conversation

jorisdon
Copy link
Contributor

@jorisdon jorisdon commented Sep 26, 2024

Issue number: Closes #308

Summary

Changes

This PR does two things:

  1. It improves the stability of build agent packer scripts, mainly by setting dpkg timeout parameters that ensure that dpkg locks (e.g. those acquired by SSM automation) don't impede installation of packages (on Ubuntu) and using dnf instead of yum (on Amazon Linux 2023).
  2. It removes configuration variables that weren't used.
  3. It lowers the WinRM connection timeout from 1 hour to 15 minutes, to give faster feedback in case firewalls are blocking WinRM connections.

User experience

Only change in user experience is that there should now be fewer packer build failures.

Checklist

If your change doesn't seem to apply, please leave them unchecked.

  • I have performed a self-review of this change
  • Changes have been tested
  • Changes are documented

I checked, but documentation changes are not necessary for this PR.

Is this a breaking change? No

Acknowledgment

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Disclaimer: We value your time and bandwidth. As such, any pull requests created might not be successful.

Copy link
Member

@kylesomers kylesomers left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Include the WinRM timeout configuration from #309 in this PR then we can close out that one.

@jorisdon jorisdon requested a review from kylesomers September 26, 2024 13:27
Copy link
Contributor

@henrykie henrykie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving.

We should look to combine these AMI builds under a single template to reduce duplicate config. Packer is build to provision multiple AMIs off various sources in one template. Not a priority.

@jorisdon jorisdon merged commit 9c32ff0 into main Sep 27, 2024
5 checks passed
@jorisdon jorisdon deleted the jorisdon/fix-build-agents-packer branch September 27, 2024 07:29
kylesomers pushed a commit that referenced this pull request Sep 27, 2024
…meout to 15 minutes, remove packer variables that aren't needed (#318)
jcwolfaws pushed a commit to jcwolfaws/cloud-game-development-toolkit that referenced this pull request Dec 10, 2024
…meout to 15 minutes, remove packer variables that aren't needed (aws-games#318)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: Windows Build Agent Packer fails due to missing install_git variable
3 participants