Initial work to get Fargate and Fargate_spot working #243
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Where do I begin? It was actually much easier to integrate with Fargate than I imagined, as everything was reusable, just really adding some if/else statements and ignoring EC2 instances for tasks that are Fargate.
Please review the code below, and make any changes to it that you feel are necessary to align it with your standards. I'm certainly not a developer, I know enough to get around.
A few things to note.
Fargate Spot
, you'll need to make sure you have set up capacity providers in the cluster when you build it.Fargate
in the configuration, you MUST also set an Execution Role, also in the config.Run as spot
you can ignore the pricing piece, as ECS Fargate spot doesn't let youbid
for prices.Fargate
, it doesn't matter if you choosePrivileged
or not, the code will not try to make a Fargate container privileged to avoid a failure.Fargate
, you cannot currently add your own Mount points to the instance. I didn't have time to work through that, as SourcePath is not a valid Fargate option and we don't need to mount things in our docker agents.Cheers,
Timothy