Skip to content

added script for bootstrapping EasyBuild#531

Merged
boegel merged 24 commits intoeasybuilders:developfrom
boegel:bootstrap
Mar 22, 2013
Merged

added script for bootstrapping EasyBuild#531
boegel merged 24 commits intoeasybuilders:developfrom
boegel:bootstrap

Conversation

@boegel
Copy link
Copy Markdown
Member

@boegel boegel commented Mar 11, 2013

We should set up a dedicated Jenkins test for this, so we can rely on it to keep on working in the future...

boegel and others added 20 commits February 11, 2013 17:32
… in Python; one issue remain with final EasyBuild installation (see easy-install.pth file in pylibdir)
…ome cases (e.g. with a Tcl (non-C) environment modules installation)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this the same distutils.sysconfig stuff?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, it's more complex than that actually... distutils.sysconfig only gives one or the other (lib or lib64), but apparently in some cases lib is used even though distutils.sysconfig returns a lib64 path. Hardcoding somewhere probably, so we really need to consider both.
This popped up during the EasyBuild hackathon in Cyprus when testing eb on JUROPA.

@boegel
Copy link
Copy Markdown
Member Author

boegel commented Mar 21, 2013

Fixed remarks, please reconsider.

Comment thread easybuild/scripts/bootstrap_eb.py Outdated
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hardcoded modulecmd, not all sites have this. need script (also in EB) to look for propoer command. if you're not fixing it, open an issue.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Won't fix that now, since I need to figure out a good way to handle this.

Added a note w.r.t. the bootstrap script in #532.

@stdweird
Copy link
Copy Markdown
Contributor

@boegel some small remarks, nothing really blocking though.

@boegel
Copy link
Copy Markdown
Member Author

boegel commented Mar 22, 2013

Adressed remarks, please reconsider. The v1.3 and up codepaths can't be tested now, since v1.3 is not released yet.

We'll need to retest the bootstrap after the v1.3 release, I made a note of that in https://github.com/hpcugent/easybuild/wiki/Release-process.

@boegel
Copy link
Copy Markdown
Member Author

boegel commented Mar 22, 2013

Argh, wait, testing failed, grr. Will fix that first.

… up more recent locally installed EasyBuild packages
@boegel
Copy link
Copy Markdown
Member Author

boegel commented Mar 22, 2013

Fixed the issue I was swearing about.
Please recheck, and test on your end, before I merge it in please.

@stdweird
Copy link
Copy Markdown
Contributor

@boegel bootstrap script needs a version of some sort

@boegel
Copy link
Copy Markdown
Member Author

boegel commented Mar 22, 2013

@stdweird: You mean, a constant like EB_BOOTSTRAP_VERSION that we can easily forget to update? ;)

@stdweird
Copy link
Copy Markdown
Contributor

as opposed to 'hey i tried the bootstrap that someone mailed but it doesn't work' and then you try to figure out what version it was since the other side is sure he dowmloaded it from the correct location?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

insert the check if this is run as root that is in main.py

@stdweird
Copy link
Copy Markdown
Contributor

root check works

new bug in sudo env

== temporary log file in case of crash /tmp/easybuild-PiVCzK.log
Traceback (most recent call last):
  File "bootstrap_eb.py", line 533, in <module>
    main()
  File "bootstrap_eb.py", line 364, in main
    stage2(tmpdir, versions, install_path)
  File "bootstrap_eb.py", line 306, in stage2
    easybuild_main()
  File "/tmp/tmpOp4gPP/eb_stage1/lib/python2.6/site-packages/easybuild_framework-1.2.0-py2.6.egg/easybuild/main.py", line 256, in main
    os.chdir(os.environ['PWD'])
  File "/usr/lib64/python2.6/UserDict.py", line 22, in __getitem__
    raise KeyError(key)
KeyError: 'PWD'

use os.getcwd() instead os.environ['PWD'] ? or save os.getcwd() in some variable first

@boegel
Copy link
Copy Markdown
Member Author

boegel commented Mar 22, 2013

added check to disallow root, obtain global eb version in a more strict way, such that local easybuild-framework installations are ignored (i.e., use python -S)

Tested on 3 or 4 totally different systems, I'd say it's good to go now...

@stdweird
Copy link
Copy Markdown
Contributor

@boegel try as this

[root@freeipa-sl64-2 tmp]# sudo -u stdweird python bootstrap_eb.py /tmp

@boegel
Copy link
Copy Markdown
Member Author

boegel commented Mar 22, 2013

@stdweird: I consider this a minor issue, because this also warrants the check in EasyBuild itself to be enhanced... Please open an issue for this, I won't fix it now.

boegel added a commit that referenced this pull request Mar 22, 2013
added script for bootstrapping EasyBuild
@boegel boegel merged commit 8c9e499 into easybuilders:develop Mar 22, 2013
@stdweird
Copy link
Copy Markdown
Contributor

see #551 for the sudo issue

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

Successfully merging this pull request may close these issues.

2 participants