Confirmed users
107
edits
No edit summary |
|||
Line 66: | Line 66: | ||
The two most basic commands list a manifest and validate the local files against the manifest. The list command lists out all of the files in the manifest as well as whether they are present and/or valid. The return code from listing is zero unless there was an error in listing the files. Absent or invalid files will still result in an exit code of zero if there was no error in the listing process. The validate command is used to check if all the files in the manifest are present and valid. The exit code for validating is zero if all files in the manifest are present and their hash matches the manifest. It is non-zero if any file is missing locally or the file does not have the same hash as the manifest. | The two most basic commands list a manifest and validate the local files against the manifest. The list command lists out all of the files in the manifest as well as whether they are present and/or valid. The return code from listing is zero unless there was an error in listing the files. Absent or invalid files will still result in an exit code of zero if there was no error in the listing process. The validate command is used to check if all the files in the manifest are present and valid. The exit code for validating is zero if all files in the manifest are present and their hash matches the manifest. It is non-zero if any file is missing locally or the file does not have the same hash as the manifest. | ||
= | = How to upload to tooltool = | ||
== Preliminary notes: == | |||
* The server used for uploads (AKA tooltool upload server) is tooltool-uploads.pub.build.mozilla.org (no VPN required) | |||
* Currently, artifacts uploaded to the tooltool upload server can be made visible to two tooltool download servers: | |||
:* Public tooltool download server: http://tooltool.pub.build.mozilla.org/temp-sm-stuff/sha512/ | |||
::* all uploads to /tooltool/uploads/user/pub on the upload server (more details below) will be visible here | |||
:* Private tooltool download server http://tooltool.pvt.build.mozilla.org/tooltool/sha512 AKA http://runtime-binaries.pvt.build.mozilla.org/tooltool/sha512 AKA https://secure.pub.build.mozilla.org/tooltool/pvt/build/sha512/ | |||
::* all uploads to /tooltool/uploads/user/pvt on the upload server (more details below) will be visible here | |||
== Pre-requisites to run an upload == | |||
* You need a unix account on the tooltool upload server, and an upload folder for each visibility level currently two visibility levels are supported (pub and pvt), so what is needed is folders /tooltool/uploads/$user/pub and /tooltool/uploads/$user/pvt | |||
* You need ssh properly configured to access the tooltool upload server | |||
* You need rsync | |||
* You need tooltool! https://github.com/mozilla/build-tooltool/blob/master/tooltool.py | |||
=== Let's update a bunch of files! === | |||
* Create a local folder (name it as you like) and put in it all the files you want to upload | |||
* Run the tooltool distribute command (see example below) | |||
That's it! | |||
The distribute command will take care of | |||
* determining the sha512 checksum of all the files | |||
* creating a tooltool manifest file for those files, which will be included in a newly created folder with the same name as the upload folder plus the .TOOLTOOL_PACKAGE suffix | |||
* transferring the files to the tooltool upload server using rsync | |||
Example: | |||
# Folder /Users/sbruno/upload contains file1.tar.gz file2.tar.gz and file3.tar.gz | |||
tooltool.py distribute \ | |||
--folder /Users/$user/upload \ | |||
--message "Bug 123456 - artifacts needed for this and that" \ | |||
--user $user \ | |||
--host tooltool-uploads.pub.build.mozilla.org \ | |||
--path "/tooltool/uploads/$user/pub" | |||
The parameters are: | |||
--folder: the folder containing the files you want to upload | |||
--message: any comment you may want to write about this upload | |||
--user: the user to access the tooltool upload server | |||
--host: the upload server host or IP | |||
--path: the target folder on the upload server | |||
Use /tooltool/uploads/<your_username>/pub to upload to the public download server | |||
Use /tooltool/uploads/<your_username>/pvt to upload to the private download server | |||
In this case, a new folder named /Users/$user/upload.TOOLTOOL_PACKAGE will be created, containing the manifest for the files involved in this upload operation. | |||
== What now? == | |||
You should receive in a few minutes an email confirming that your upload has been correctly processed on the upload server, and the files should appear in the relevant download server with their correct digest (and in all mirrors, if any, setup for the same visibility level). | |||
The default email address used for these notifications is user@mozilla.com, where user is the user you use to access the upload server. | |||
All metadata about the upload is stored in the upload server. | |||
See [[ReleaseEngineering:Buildduty:Other Duties#How to upload to Tooltool]] | See [[ReleaseEngineering:Buildduty:Other Duties#How to upload to Tooltool]] | ||