{"action":"created","issue":{"url":"https://api.github.com/repos/gkop/elastic-beanstalk-ruby/issues/2","repository_url":"https://api.github.com/repos/gkop/elastic-beanstalk-ruby","labels_url":"https://api.github.com/repos/gkop/elastic-beanstalk-ruby/issues/2/labels{/name}","comments_url":"https://api.github.com/repos/gkop/elastic-beanstalk-ruby/issues/2/comments","events_url":"https://api.github.com/repos/gkop/elastic-beanstalk-ruby/issues/2/events","html_url":"https://github.com/gkop/elastic-beanstalk-ruby/issues/2","id":16921825,"number":2,"title":"yum wkhtmltopdf causes deployment error.","user":{"login":"porteaux","id":4370625,"avatar_url":"https://avatars.githubusercontent.com/u/4370625?v=3","gravatar_id":"","url":"https://api.github.com/users/porteaux","html_url":"https://github.com/porteaux","followers_url":"https://api.github.com/users/porteaux/followers","following_url":"https://api.github.com/users/porteaux/following{/other_user}","gists_url":"https://api.github.com/users/porteaux/gists{/gist_id}","starred_url":"https://api.github.com/users/porteaux/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/porteaux/subscriptions","organizations_url":"https://api.github.com/users/porteaux/orgs","repos_url":"https://api.github.com/users/porteaux/repos","events_url":"https://api.github.com/users/porteaux/events{/privacy}","received_events_url":"https://api.github.com/users/porteaux/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2013-07-18T14:10:11Z","updated_at":"2016-05-18T08:22:26Z","closed_at":"2013-08-12T16:09:59Z","body":"first thanks for sharing this useful document to the global comunity. I have already installed git, gnuplot, and gsl packages. this is what my current config.ruby looks like:\r\n\r\n----------------------------------------------------------------------\r\n # These are things that make sense for any Ruby application\r\n\r\n # Install git in order to be able to bundle gems from git\r\npackages\r\n\r\n  yum:\r\n    git: []\r\n    gnuplot: []\r\n    gsl: []\r\n #    wkhtmltopdf: []\r\n\r\ncommands:\r\n  # Run rake with bundle exec to be sure you get the right version\r\n  add_bundle_exec:\r\n    test: test ! -f /opt/elasticbeanstalk/support/.post-provisioning-complete\r\n    cwd: /opt/elasticbeanstalk/hooks/appdeploy/pre\r\n    command: perl -pi -e 's/(rake)/bundle exec $1/' 11_asset_compilation.sh\r\n  # Bundle with --deployment as recommended by bundler docs\r\n  #   cf. http://gembundler.com/v1.2/rationale.html under Deploying Your Application\r\n  add_deployment_flag:\r\n    test: test ! -f /opt/elasticbeanstalk/support/.post-provisioning-complete\r\n    cwd: /opt/elasticbeanstalk/hooks/appdeploy/pre\r\n    command: perl -pi -e 's/(bundle install)/$1 --deployment/' 10_bundle_install.sh\r\n  # Vendor gems to a persistent directory for speedy subsequent bundling\r\n  make_vendor_bundle_dir:\r\n    test: test ! -f /opt/elasticbeanstalk/support/.post-provisioning-complete\r\n    command: mkdir /var/app/support/vendor_bundle\r\n  # Store the location of vendored gems in a handy env var\r\n  set_vendor_bundle_var:\r\n    test: test ! -f /opt/elasticbeanstalk/support/.post-provisioning-complete\r\n    cwd: /opt/elasticbeanstalk/support\r\n    command: sed -i '12iexport EB_CONFIG_APP_VENDOR_BUNDLE=$EB_CONFIG_APP_SUPPORT/vendor_bundle' envvars\r\n  # The --deployment flag tells bundler to install gems to vendor/bundle/, so\r\n  # symlink that to the persistent directory\r\n  symlink_vendor_bundle:\r\n    test: test ! -f /opt/elasticbeanstalk/support/.post-provisioning-complete\r\n    cwd: /opt/elasticbeanstalk/hooks/appdeploy/pre\r\n    command: sed -i '6iln -s $EB_CONFIG_APP_VENDOR_BUNDLE ./vendor/bundle' 10_bundle_install.sh\r\n  # Don't run the above commands again on this instance\r\n  #   cf. http://stackoverflow.com/a/16846429/283398\r\n  z_write_post_provisioning_complete_file:\r\n    cwd: /opt/elasticbeanstalk/support\r\n    command: touch .post-provisioning-complete\r\n\r\n----------------------------------------------------------------------\r\n\r\nwhen I uncomment:\r\n\r\n #    wkhtmltopdf: []\r\n\r\nAnd then deploy the new version to my eb app.\r\n\r\nMy eb console for the environment shows:\r\n\r\n2013-07-18 09:55:36 UTC-0400\tERROR\tFailed to deploy application.\r\n2013-07-18 09:55:35 UTC-0400\tERROR\tResponses from [i-59892133] were received, but the commands failed.\r\n2013-07-18 09:55:22 UTC-0400\tINFO\tDeploying new version to instance(s)."},"comment":{"url":"https://api.github.com/repos/gkop/elastic-beanstalk-ruby/issues/comments/219958498","html_url":"https://github.com/gkop/elastic-beanstalk-ruby/issues/2#issuecomment-219958498","issue_url":"https://api.github.com/repos/gkop/elastic-beanstalk-ruby/issues/2","id":219958498,"user":{"login":"RafalStrab","id":5604816,"avatar_url":"https://avatars.githubusercontent.com/u/5604816?v=3","gravatar_id":"","url":"https://api.github.com/users/RafalStrab","html_url":"https://github.com/RafalStrab","followers_url":"https://api.github.com/users/RafalStrab/followers","following_url":"https://api.github.com/users/RafalStrab/following{/other_user}","gists_url":"https://api.github.com/users/RafalStrab/gists{/gist_id}","starred_url":"https://api.github.com/users/RafalStrab/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RafalStrab/subscriptions","organizations_url":"https://api.github.com/users/RafalStrab/orgs","repos_url":"https://api.github.com/users/RafalStrab/repos","events_url":"https://api.github.com/users/RafalStrab/events{/privacy}","received_events_url":"https://api.github.com/users/RafalStrab/received_events","type":"User","site_admin":false},"created_at":"2016-05-18T08:22:26Z","updated_at":"2016-05-18T08:22:26Z","body":"For the latest (0.12.3) version I got this working with below code:\r\n`# install WKHTML\r\n  03_command:\r\n    command: yum install xz urw-fonts libXext openssl-devel libXrender\r\n  04_command:\r\n    command: wget http://download.gna.org/wkhtmltopdf/0.12/0.12.3/wkhtmltox-0.12.3_linux-generic-amd64.tar.xz\r\n  05_command:\r\n    command: tar -xJf wkhtmltox-0.12.3_linux-generic-amd64.tar.xz\r\n  06_command:\r\n    command: cp wkhtmltox/bin/wkhtmltopdf /usr/local/bin/wkhtmltopdf\r\n  07_command:\r\n    command: cp wkhtmltox/bin/wkhtmltoimage /usr/local/bin/wkhtmltoimage`"}}