add new arches to configs and build script

This commit is contained in:
Nadezhda Fedorova 2024-11-06 16:23:04 +03:00
parent f186fe4202
commit 16125d5010
7 changed files with 110 additions and 100 deletions

View File

@ -238,6 +238,9 @@ class CB:
self._repository_url = cfg.get('repository_url',
'copy:///space/ALT/{branch}')
self._other_repo_url = cfg.get('other_repo_url',
'http://ftp.altlinux.org/pub/distributions/ALTLinux/ports/{arch}')
self._image_repo = cfg.get('image_repo')
self.patch_mp_prog = get_overrided('patch_mp_prog')
@ -315,6 +318,14 @@ class CB:
self._repository_url)
return url.format(branch=branch, arch=arch)
def other_repo_url(self, branch: str, arch: str) -> str:
url = self._branches[branch]['arches'][arch].get('repository_url')
if url is None:
url = self._branches[branch].get('repository_url',
self._repository_url)
return url.format(branch=branch, arch=arch)
def image_repo(self, branch: str, arch: str) -> str:
url = self._branches[branch]['arches'][arch].get('image_repo')
if url is None:
@ -394,6 +405,10 @@ Dir::Etc::preferencesparts "/var/empty";
with open(f'{apt_dir}/sources.list.{branch}.{arch}', 'w') as f:
sources_list = f'rpm {repo} {arch} classic\n'
if arch in ['loongarch64', 'riscv64']:
sources_list = f'rpm {repo} {branch}/{arch} classic\n'
sources_list += f'rpm {repo} {branch}/noarch classic\n'
else:
if arch == 'x86_64':
sources_list += f'rpm {repo} {arch}-i586 classic\n'
if arch not in self.bad_arches:

View File

@ -8,6 +8,12 @@ rebuild_after:
days: 5
images:
rootfs-minimal:
target: ve/docker
kinds:
- tar.xz
tests:
- method: docker
rootfs-systemd:
target: ve/systemd-networkd
kinds:
@ -37,19 +43,6 @@ images:
- method: lxd
scripts:
- securetty
cloud:
target: vm/cloud-systemd
kinds:
- qcow2c
scripts:
- machine_id
packages:
- update-kernel
- apt-scripts
- systemd-settings-disable-kill-user-processes
rename:
regex: '(.*)\.qcow2c$'
to: '\1.qcow2'
branches:
Sisyphus:
@ -59,11 +52,11 @@ branches:
p10:
arches:
aarch64:
branding: alt-starterkit
branding: alt-container
p11:
arches:
aarch64:
branding: alt-starterkit
branding: alt-container
scripts:
machine_id:

View File

@ -1,6 +1,6 @@
---
remote: 'cloud@172.16.0.2:/home/cloud/images/{branch}/{arch}'
repository_url: copy:///space/ALT/{branch}
remote: '/home/builder/images/{branch}/{arch}'
repository_url: http://ftp.altlinux.org/pub/distributions/ALTLinux/ports/{arch}
try_build_all: True
log_level: debug
@ -41,18 +41,12 @@ images:
scripts:
- securetty
- netsharedpath
exclude_branches:
- c8
branches:
Sisyphus:
arches:
ppc64le:
p10:
arches:
ppc64le:
armh:
branding: alt-starterkit
loongarch64:
riscv64:
scripts:
securetty:

View File

@ -8,6 +8,12 @@ rebuild_after:
days: 5
images:
rootfs-minimal:
target: ve/docker
kinds:
- tar.xz
tests:
- method: docker
rootfs-systemd:
target: ve/systemd-networkd
kinds:
@ -45,12 +51,12 @@ branches:
arches:
i586:
x86_64:
branding: alt-starterkit
branding: alt-container
p11:
arches:
i586:
x86_64:
branding: alt-starterkit
branding: alt-container
scripts:
securetty:

View File

@ -0,0 +1,68 @@
---
remote: 'builder@cloud-builder.office.basealt.ru:/home/builder/images/{branch}/{arch}'
repository_url: http://mirror.yandex.ru/altlinux/{branch}/branch
try_build_all: True
log_level: debug
rebuild_after:
days: 5
images:
cloud:
target: vm/cloud-systemd
kinds:
- qcow2c
scripts:
- machine_id
packages:
- update-kernel
- apt-scripts
- systemd-settings-disable-kill-user-processes
rename:
regex: '(.*)\.qcow2c$'
to: '\1.qcow2'
branches:
Sisyphus:
arches:
aarch64:
repository_url: http://ftp.altlinux.org/pub/distributions/ALTLinux/{branch}
p10:
arches:
aarch64:
branding: alt-starterkit
p11:
arches:
aarch64:
branding: alt-starterkit
scripts:
machine_id:
contents: |
#!/bin/sh -exu
etc_machine_id=/etc/machine-id
dbus_machine_id=/var/lib/dbus/machine-id
rm -f "$etc_machine_id" "$dbus_machine_id"
touch "$etc_machine_id"
global: no
number: 90
securetty:
contents: |
#!/bin/sh
echo pts/0 >> /etc/securetty
echo pts/1 >> /etc/securetty
global: no
number: 1
apt_sources:
contents: |
#!/bin/sh
repo_source=/etc/apt/sources.list.d/altsp.list
[ -s "$repo_source" ] || exit 0
sed -i -E 's/^\s*#(rpm.*http)/\1/' "$repo_source"
global: no
number: 80
...

View File

@ -1,32 +0,0 @@
---
remote: 'builder@cloud-builder.office.basealt.ru:/home/builder/images/{branch}/{arch}'
repository_url: http://mirror.yandex.ru/altlinux/{branch}/branch
try_build_all: True
log_level: debug
rebuild_after:
days: 5
images:
rootfs-minimal:
target: ve/docker
kinds:
- tar.xz
tests:
- method: docker
branches:
Sisyphus:
arches:
aarch64:
repository_url: http://ftp.altlinux.org/pub/distributions/ALTLinux/{branch}
p10:
arches:
aarch64:
branding: alt-container
p11:
arches:
aarch64:
branding: alt-container
...

View File

@ -1,34 +0,0 @@
---
remote: '/home/builder/images/{branch}/{arch}'
repository_url: copy:///space/ALT/{branch}
try_build_all: True
log_level: debug
rebuild_after:
days: 5
images:
rootfs-minimal:
target: ve/docker
kinds:
- tar.xz
tests:
- method: docker
branches:
Sisyphus:
arches:
i586:
x86_64:
p10:
arches:
i586:
x86_64:
branding: alt-container
p11:
arches:
i586:
x86_64:
branding: alt-container
...