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

Deploy script fixes & cleanup #405

Merged
merged 6 commits into from Mar 2, 2015
Merged

Deploy script fixes & cleanup #405

merged 6 commits into from Mar 2, 2015

Conversation

edmorley
Copy link
Contributor

@edmorley edmorley commented Mar 2, 2015

This includes fixes for bug 1059814, bug 1135798, bug 1088705 & bug 1138392.
Please see the individual commit diffs and multi-line commit messages for easier review :-)

Ed Morley added 6 commits March 2, 2015 15:47
The directory of the currently running script is already on the path:
https://docs.python.org/2/tutorial/modules.html#the-module-search-path
...so adding it is unnecessary.

In addition, I don't believe we need the treeherder-service directory on
the path, since we don't directly import anything from there.
The current fetch/reset/checkout doesn't correctly update the working
directory when switching between branches. This new approach is
recommended by:
http://stackoverflow.com/a/9589927
We don't use git submodules, so let's not bother trying to update them.
Previously the revision file was regenerated after it had already been
rsynced to the webheads, and as such the publicly accessible file
displayed the previous revision, not the new revision.
The git reset already outputs the SHA/commit message for HEAD so
most of this additional output is unnecessary.
Anything in the deploy script decorated with @task or @hostgroups ends
up having it's progress displayed in IRC by the bot - eg:
[2015-02-23 20:09:40] Finished deploy_log (0.454s)

However, the "deploy_X" @hostgroup functions were actually only
rsyncing the code (which is fast compared to restarting the processes),
but the name used to imply the whole deploy for that node type was
complete.

The new structure not only reduces code duplication, but makes the IRC
output more accurate, to provide a better idea as to what stage the
deploy is at, and which are the problematic steps in the case of errors.
@edmorley edmorley self-assigned this Mar 2, 2015
@edmorley edmorley merged commit 87f7a32 into master Mar 2, 2015
@edmorley edmorley deleted the deploy-script-cleanup branch March 2, 2015 18:21
edmorley pushed a commit that referenced this pull request May 20, 2015
Update treeherder ui to use new optioncollectionhash API
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant