vdist
vdist copied to clipboard
Freebsd packages support
Hi there.
How about implementing support of FreeBSD packages? There is no ready to use solution for converting python app with all dependencies to such format.
Hope it's a reasonable idea :)
Hi,
It's definitely a reasonable idea. Unfortunately FPM (which is what vdist runs under the hood) doesn't yet support FreeBSD packages, but that doesn't mean it can't be done. In fact, vdist is built so that adding support for a different OS can be added by using so called profiles, in which you can refer to a script template (usually a shell script). When you look at the shell scripts that come with vdist for Debian/Ubuntu and Redhat/CentOS, you can see how this is implemented:
https://github.com/objectified/vdist/blob/master/vdist/profiles/centos.sh https://github.com/objectified/vdist/blob/master/vdist/profiles/debian.sh
During runtime, these scripts are rendered as Jinja2 templates, substituting values where needed. Which template vdist uses is determined by so called "profiles". You can create custom profiles pointing to your own templates, as explained here:
https://vdist.readthedocs.org/en/latest/howtocustomize/
I don't actually use FreeBSD myself, but I'd be happy to integrate a template that works on FreeBSD into vdist if you'd create a pull request. If you're having trouble getting things to work, I can assist when necessary. If all else fails, I'm willing to see if I can fire up a FreeBSD machine somewhere to see if I can get it to work myself.
Thanks for your response! I am going to try implementing FreeBSD support. Also I've found repo https://github.com/shigin/dist2free that probably could be used as initial point for template.