Introduce stage3 downloads.
This expands the sync_jobs.py parameter to contain the release codename, which is respectfully documented in the README.md file.
This commit is contained in:
parent
2be199a214
commit
4da1117a3f
|
@ -43,26 +43,26 @@ optional arguments:
|
|||
|
||||
The `jobname` argument should be in a specific format. It should contain
|
||||
the requester's email, which sdk was chosen, the requested architecture,
|
||||
and a timestamp.
|
||||
codename, and a timestamp.
|
||||
|
||||
In case of vm-sdk or live-sdk, these would look like:
|
||||
|
||||
```
|
||||
parazyd@dyne.org-vm_amd64-1537977964
|
||||
parazyd@dyne.org-live_amd64-1537977964
|
||||
parazyd@dyne.org-vm_amd64_ascii-1537977964
|
||||
parazyd@dyne.org-live_amd64_beowulf-1537977964
|
||||
```
|
||||
|
||||
In case of arm-sdk, we also need to know the board we're building for:
|
||||
|
||||
```
|
||||
parazyd@dyne.org-arm_armhf_sunxi-1537977964
|
||||
parazyd@dyne.org-arm_armhf_ascii_sunxi-1537977964
|
||||
```
|
||||
|
||||
All of this combined, the required command to add a new job to Jenkins
|
||||
would look something like the following:
|
||||
|
||||
```
|
||||
sync_jobs.py -a parazyd@dyne.org-vm_amd64-1537977964
|
||||
sync_jobs.py -a parazyd@dyne.org-vm_amd64_ascii-1537977964
|
||||
```
|
||||
|
||||
In case of removing or building an existing job, all of the above applies the
|
||||
|
|
|
@ -20,16 +20,36 @@ def add_job(jobname):
|
|||
desc = 'WebSDK build for: %s\nStarted: %s' % (info[0], info[2])
|
||||
sdk = info[1].split('_')[0]
|
||||
arch = info[1].split('_')[1]
|
||||
codename = info[1].split('_')[2]
|
||||
blenddir = join(jobpath, jobname)
|
||||
blendfile = join(blenddir, 'Dockerfile')
|
||||
|
||||
if codename == 'ascii':
|
||||
relvars = 'release=ascii && version=2.0.0'
|
||||
elif codename == 'beowulf':
|
||||
relvars = 'release=beowulf && version=3.0.0'
|
||||
else:
|
||||
# Default to Ascii
|
||||
relvars = 'release=ascii && version=2.0.0'
|
||||
|
||||
if sdk == 'arm':
|
||||
board = info[1].split('_')[2]
|
||||
zshcmd = 'load devuan %s %s && build_image_dist' % (board, blendfile)
|
||||
board = info[1].split('_')[3]
|
||||
zshcmd = '\
|
||||
load devuan %s %s && \
|
||||
%s && \
|
||||
build_image_dist' % (board, blendfile, relvars)
|
||||
|
||||
elif sdk == 'live':
|
||||
zshcmd = 'load devuan %s %s && build_iso_dist ' % (arch, blendfile)
|
||||
zshcmd = '\
|
||||
load devuan %s %s && \
|
||||
%s && \
|
||||
build_iso_dist' % (arch, blendfile, relvars)
|
||||
|
||||
elif sdk == 'vm':
|
||||
zshcmd = 'load devuan %s && build_vagrant_dist' % (blendfile)
|
||||
zshcmd = '\
|
||||
load devuan %s && \
|
||||
%s && \
|
||||
build_vagrant_dist' % (blendfile, relvars)
|
||||
|
||||
command = "zsh -f -c 'source sdk && %s'" % zshcmd
|
||||
command = html.escape(command)
|
||||
|
@ -37,6 +57,7 @@ def add_job(jobname):
|
|||
replacements = [('DESC', desc),
|
||||
('SDK', sdk),
|
||||
('ARCH', arch),
|
||||
('CODENAME', codename),
|
||||
('COMMAND', command),
|
||||
('BLENDDIR', blenddir)]
|
||||
|
||||
|
|
|
@ -36,6 +36,12 @@
|
|||
<command>
|
||||
scp -r sdk:{{{BLENDDIR}}} {{{BLENDDIR}}} || exit 1
|
||||
git submodule update --init --recursive --checkout || exit 1
|
||||
|
||||
mkdir -p tmp
|
||||
cd tmp
|
||||
wget https://sdk.dyne.org:4443/job/devuan-{{{CODENAME}}}-{{{ARCH}}}-stage3/lastSuccessfulBuild/artifact/tmp/bootstrap-devuan-{{{ARCH}}}-stage3.tgz
|
||||
cd -
|
||||
|
||||
{{{COMMAND}}} || exit 1
|
||||
rm -rf {{{BLENDDIR}}}
|
||||
</command>
|
||||
|
|
Loading…
Reference in New Issue