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

Attempt to support new manifest format and fetch-bmo.py #8

Merged
merged 8 commits into from
Jun 11, 2020

Conversation

Callek
Copy link
Contributor

@Callek Callek commented Jun 10, 2020

No description provided.

@Callek Callek requested a review from escapewindow June 10, 2020 19:36
@escapewindow
Copy link
Contributor

escapewindow commented Jun 10, 2020

[task 2020-06-10T19:36:50.619Z] Exception: Invalid manifest:
[task 2020-06-10T19:36:50.619Z] extra keys not allowed @ data[u'fetch']
[task 2020-06-10T19:36:50.619Z] required key not provided @ data[u'url']

We probably have to update https://github.com/mozilla-releng/adhoc-signing/blob/master/taskcluster/adhoc_taskgraph/signing_manifest.py#L38-L52 .

If you can also add github-pull-request to this line, we should get a fetch task in this PR.

@@ -0,0 +1,253 @@
#!/usr/bin/python3 -u

Choose a reason for hiding this comment

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

This file should either live in taskcluster/docker/fetch or taskcluster/script/fetch.

@@ -24,6 +24,9 @@ RUN apt-get update && \

# %include-run-task

# %include taskcluster/run-task/fetch-bmo.py
ADD topsrcdir/taskcluster/run-task/fetch-bmo.py /builds/worker/bin/fetch-bmo.py

Choose a reason for hiding this comment

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

I would be inclined to use /usr/local/bin/fetch-bmo.

cmd = [
'bash',
'-c',
'cd {} && '

Choose a reason for hiding this comment

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

Instead of setting the current directory, you should pass the full path to the destination here.

'bash',
'-c',
'cd {} && '
'/usr/bin/python3 {} {}'.format(

Choose a reason for hiding this comment

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

I would be inclined to defer to the shebang, rather than explicitly calling python. This will require chmod +x in the dockerfile.

@Callek Callek force-pushed the fetch-bmo branch 2 times, most recently from 1778f4b to 72f1eda Compare June 10, 2020 20:33
fetch['type'] = manifest["fetch"].get('type', 'static-url')
if fetch['type'] == 'static-url':
fetch["url"] = manifest["fetch"]["url"]
if manifest.get('gpg-signature'):
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we put gpg-signature into the fetch block directly, rather than look for it elsewhere in the manifest and put it in the fetch block?

@Callek Callek force-pushed the fetch-bmo branch 2 times, most recently from f5af14e to 9160e56 Compare June 10, 2020 21:00
@escapewindow escapewindow merged commit 45117e2 into master Jun 11, 2020
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.

None yet

3 participants