Skip to content

¨dockerizePip: true¨ in Ubuntu 16.04 does not work (docker) #158

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

Closed
fadonoso opened this issue Mar 8, 2018 · 2 comments
Closed

¨dockerizePip: true¨ in Ubuntu 16.04 does not work (docker) #158

fadonoso opened this issue Mar 8, 2018 · 2 comments

Comments

@fadonoso
Copy link

fadonoso commented Mar 8, 2018

Hi there,
I have my project in MacOS and works really good, the docker image was called and everything was packaged fine. However, in my ubuntu 16.04 can not reach the docker image. I get this error:

invalid reference format

I'm using the exact serverless.yml ( 'except for this change: dockerizePip: true'), so it is not that I´m using upper cases or something like that.

Someone has crossed with this issue before?

Thanks

@fadonoso
Copy link
Author

fadonoso commented Mar 9, 2018

I fixed the problem. It was not directly related with the plugin, I had badly installed serverless with sudo.
So first I uninstall 'npn' and 'nodejs' and install them through 'nvm'.

1.- Install nvm: https://github.com/creationix/nvm/blob/master/README.md#installation
2.- Install serverless: npm install serverless -g
3.- Install plugin: serverless plugin install -n serverless-python-requirements
5.- Install docker: https://docs.docker.com/install/linux/docker-ce/ubuntu/#install-docker-ce-1
5.- Add your user to docker: sudo usermod -a -G docker $USER
6.- Reboot

That is!!.
I hope this could help others in the future.

@dschep
Copy link
Contributor

dschep commented Mar 12, 2018

Glad you got it working! Yeah, real globally installed node is always a pain. and an especially bad idea given the recent sudo npm chown bugs. I always use nvm.

Just a note, if you're on 64 bit linux and your binarydependencies are available as manylinux wheels (things like numpy & psycopg[now as psycopg-binary] are), you don't need docker. you can use the special value of non-linux for the dockerizePip option to skip using docker on linux machines, We use this option at @unitedincome so that mac users(almost all the developers) use docker, but CI and linux devs (just me) don't.

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

No branches or pull requests

2 participants