Skip to content
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

Package euca-deploy for RPM based distros #29

Open
viglesiasce opened this issue Apr 27, 2015 · 10 comments
Open

Package euca-deploy for RPM based distros #29

viglesiasce opened this issue Apr 27, 2015 · 10 comments

Comments

@viglesiasce
Copy link
Owner

We need to be able to install euca-deploy and its dependencies via yum.

Currently the dependencies are:

Unpackaged python libraries

  • Fabric (this drags in paramiko which is a problem on CentOS 6 afaik because of pycrypto needing to be newer, current packaging on koji.

Packages

  • PyYaml
  • python-devel
  • gcc
  • git
  • python-setuptools
@viglesiasce
Copy link
Owner Author

I started some work on this a while back:
https://bintray.com/viglesiasce/euca-deploy

I never got it to work fully due to the pycrypto issues mentioned above.

@viglesiasce
Copy link
Owner Author

The error from paramiko:

[root@h-32 ~]# euca-deploy
Traceback (most recent call last):
  File "/usr/bin/euca-deploy", line 5, in <module>
    from eucadeploy.componentdeployer import ComponentDeployer
  File "/usr/lib/python2.6/site-packages/eucadeploy/componentdeployer.py", line 7, in <module>
    from eucadeploy.chefmanager import ChefManager
  File "/usr/lib/python2.6/site-packages/eucadeploy/chefmanager.py", line 7, in <module>
    from fabric.api import *
  File "/usr/lib/python2.6/site-packages/fabric/api.py", line 11, in <module>
    from fabric.decorators import (hosts, roles, runs_once, with_settings, task,
  File "/usr/lib/python2.6/site-packages/fabric/decorators.py", line 9, in <module>
    from Crypto import Random
ImportError: cannot import name Random
[root@h-32 ~]#

@viglesiasce
Copy link
Owner Author

@mbacchi

Nice work on the packages from http://jenkins.release.eucalyptus-systems.com/job/p1-eucadeploy-build-devel-s03-rpm/4/.

A few more tweaks are needed:

  1. We need to depend on git as its used in some places
  2. Can you install the config.yml in /etc/euca-deploy/config.yml? Ill then tweak the code to look there when I am fixing better error when config.yml not provided #36

Other than those issues we are solid! Once again nice work!

@viglesiasce
Copy link
Owner Author

@mbacchi I just thought of another impending dep from the plugins branch python-stevedore:
https://admin.fedoraproject.org/pkgdb/package/python-stevedore/

Its already available in epel thankfully.

@mbacchi
Copy link
Collaborator

mbacchi commented May 20, 2015

@viglesiasce I could use your input on a couple questions:

  1. Is config.yml intended to be a proper RPM 'config file' in the way that we wouldn't want to remove it when the RPM is removed? Also when the package is upgraded it won't be overwritten due to the assumption users have modified it.
  2. I think you are asking for python-stevedore to be required as an RPM Requires: entry vs. a pip install, is that correct? I have installed it manually using pip on my test machine but I think this requirement would mean yum needs to install it for us via epel.

Thanks.
-Matt

@viglesiasce
Copy link
Owner Author

@mbacchi

  1. Users wont be tweaking this file much as far as I can tell. We do however need it to run. In an ideal world I'd like the following: we put it in place, then overwrite it on upgrade and save the previous one as a backup if its been changed. IIRC, there is a way in packaging to have it save the backup as *.rpmsave. Unfortunately I'm not savvy enough to know what that is.

  2. Correct this is a package dependency.

@mbacchi
Copy link
Collaborator

mbacchi commented May 20, 2015

From a very quick search I see that the %config directive automatically creates a .rpmsave file if the config file has been changed by the user, and is different than the file in the update RPM1, 2. If it hasn't changed from the old RPM version, it is simply overwritten. That seems to be the behavior you are looking for. What I don't know is how this is handled on removal, whether the config file is left around indefinitely.

I can do some testing to see if we can get a good understanding of how it works in practice.

@mbacchi
Copy link
Collaborator

mbacchi commented May 21, 2015

@viglesiasce try the package here, I added the dependencies and the config.yml, and tested that it won't be overwritten during an upgrade.

http://jenkins.release.eucalyptus-systems.com/job/p1-eucadeploy-build-devel-s03-rpm/6/

@mbacchi
Copy link
Collaborator

mbacchi commented May 22, 2015

@viglesiasce
Copy link
Owner Author

@mbacchi example envs look great.

Still on the plate:

  • Put in place /etc/euca-deploy/config.yml
  • Have euca-deploy check ./etc/config.yml then /etc/euca-deploy/config.yml

@mbacchi mbacchi removed their assignment May 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants