3

When I try to run

$ eb local run

I get an error:

Creating elasticbeanstalk_samplerailsdockerappapp_1...

/root/.local/lib/python3.5/site-packages/docker/utils/utils.py:591: UserWarning: docker.utils.create_host_config() is deprecated. Please use Client.create_host_config() instead.
  'docker.utils.create_host_config() is deprecated. Please use '
Pulling image xxxxx.dkr.ecr.eu-central-1.amazonaws.com/xxxxxx:latest...

ERROR: TypeError :: the JSON object must be str, not 'bytes'

I'm using ECR to store images.

How to fix that?

EDIT:

$ python --version
Python 2.7.12
$ python3 --version
Python 3.5.2
nicq
  • 2,182
  • 5
  • 22
  • 38
  • I assume the problem is due to using Python 3, in which strings are unicode strings, not bytestreams. If you don't want to change any code, use Python 2. – L3viathan Nov 22 '16 at 10:56
  • Thanks for response, but How I can do that? **eb local run** is command from EB CLI, I'm not sure which version is used. Amazon docs presents installation of python 3.4. I'm not familiar with Python and its dependencies. – nicq Nov 22 '16 at 11:19
  • 1
    I figured out how to get it to run on python 3.6, but unfortunately did not still fix my issue with the warnings about deprecations. You can see how I did it here by following my progress and links to the other questions (http://stackoverflow.com/questions/41499034/error-running-dockerrun-aws-json-file-error-valueerror-extra-data) – Joseph Astrahan Jan 07 '17 at 00:04

0 Answers0