I've been trying to automate everything about our deployment and have had some reasonable incremental success until today, when it all went backwards.
.ebextensions/01settings.config
container_commands:
01seed:
command: rake db:seed
leader_only: true
This has occasionally run, but mostly does not. When it does on a deploy, I'll see something like:
2013-08-13 21:46:55,606 [INFO] Running configSets: Infra-EmbeddedPostBuild
2013-08-13 21:46:55,607 [INFO] Running configSet Infra-EmbeddedPostBuild
2013-08-13 21:46:55,609 [INFO] Running config postbuild_0_acme_development_02e6a3b5e2d179b50d766a8dc16f8243__ebextensions_01settings_config
2013-08-13 21:46:55,609 [DEBUG] No packages specified
2013-08-13 21:46:55,609 [DEBUG] No groups specified
2013-08-13 21:46:55,609 [DEBUG] No users specified
2013-08-13 21:46:55,609 [DEBUG] No sources specified
2013-08-13 21:46:55,609 [DEBUG] No files specified
2013-08-13 21:46:55,610 [DEBUG] Running command 01seed
2013-08-13 21:46:55,610 [DEBUG] Generating defaults for command 01seed
2013-08-13 21:46:55,810 [DEBUG] Running test for command 01seed
2013-08-13 21:46:55,839 [DEBUG] Test command output:
2013-08-13 21:46:55,840 [DEBUG] Test for command 01seed passed
2013-08-13 21:47:08,019 [INFO] Command 01seed succeeded
2013-08-13 21:47:08,020 [DEBUG] No services specified
2013-08-13 21:47:08,034 [INFO] ConfigSets completed
Other times, I'll deploy the same thing to the same instance, and that same section will read:
2013-08-13 22:15:15,360 [INFO] Running configSets: Infra-EmbeddedPostBuild
2013-08-13 22:15:15,362 [INFO] Running configSet Infra-EmbeddedPostBuild
2013-08-13 22:15:15,362 [INFO] ConfigSets completed
I can't tell you how frustrating this experience has been. I plan to share this automation for the rails deployment via rake as a gem very soon, but I'm hesitant because this won't work the same every time.
What are the reasons an .ebextensions/*.config wouldn't even be attempted?
EDIT: It appears that my deep_symbolized_hash.to_yaml puts out an .ebextensions/01settings.config that looks like:
:container_commands:
:01seed:
:command: rake db:seed
:leader_only: true
So, while this is valid yaml, the elastic beanstalk configset running process of Infra-EmbeddedPostBuild just walks right by the my config without complaint.
Does that sound right? Are we really to hope that eb just swallows this?