Skip to content

Commit

Permalink
Create projects for all maintained Debian releases
Browse files Browse the repository at this point in the history
  • Loading branch information
athos-ribeiro committed Jun 19, 2018
1 parent a4a32d9 commit ec95cb1
Show file tree
Hide file tree
Showing 12 changed files with 162 additions and 87 deletions.
6 changes: 3 additions & 3 deletions salt/files/test_proj.xml → salt/files/debian_8_test.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<project name="test">
<title>test</title>
<description>test</description>
<project name="Debian:8:test">
<title>Debian 8 builds</title>
<description>Project to test Debian 8 builds</description>
<person userid="Admin" role="maintainer"/>
<repository name="Debian_8.0">
<path project="Debian:8" repository="main"/>
Expand Down
4 changes: 4 additions & 0 deletions salt/files/debian_9.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@

Repotype: debian

BuildEngine: debootstrap
9 changes: 9 additions & 0 deletions salt/files/debian_9.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<project name="Debian:9">
<title>Debian 9 DoD</title>
<description>Debian 9 DoD</description>
<person userid="Admin" role="maintainer"/>
<repository name="main">
<download arch="x86_64" url="http://deb.debian.org/debian/stretch/main" repotype="deb"/>
<arch>x86_64</arch>
</repository>
</project>
9 changes: 9 additions & 0 deletions salt/files/debian_9_test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<project name="Debian:9:test">
<title>Debian 9 builds</title>
<description>Project to test Debian 9 builds</description>
<person userid="Admin" role="maintainer"/>
<repository name="Debian_9.0">
<path project="Debian:9" repository="main"/>
<arch>x86_64</arch>
</repository>
</project>
4 changes: 2 additions & 2 deletions salt/files/debian_clang.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<project name="debclang">
<project name="Debian:Unstable:Clang">
<title>Debian Clang Rebuilds</title>
<description>test</description>
<description>Rebuild Debian Archive against Clang compiler</description>
<person userid="Admin" role="maintainer"/>
<repository name="Debian_Unstable_Clang">
<path project="Debian:Unstable" repository="main"/>
Expand Down
4 changes: 4 additions & 0 deletions salt/files/debian_testing.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@

Repotype: debian

BuildEngine: debootstrap
9 changes: 9 additions & 0 deletions salt/files/debian_testing.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<project name="Debian:Testing">
<title>Debian Testing DoD</title>
<description>Debian Testing DoD</description>
<person userid="Admin" role="maintainer"/>
<repository name="main">
<download arch="x86_64" url="http://deb.debian.org/debian/buster/main" repotype="deb"/>
<arch>x86_64</arch>
</repository>
</project>
9 changes: 9 additions & 0 deletions salt/files/debian_testing_test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<project name="Debian:Testing:test">
<title>Debian Testing builds</title>
<description>Project to test Debian Testing builds</description>
<person userid="Admin" role="maintainer"/>
<repository name="Debian_Testing">
<path project="Debian:Testing" repository="main"/>
<arch>x86_64</arch>
</repository>
</project>
98 changes: 31 additions & 67 deletions salt/files/debian_unstable.conf
Original file line number Diff line number Diff line change
@@ -1,84 +1,56 @@

Repotype: debian

# create initial user
Preinstall: base-passwd
Preinstall: user-setup
Preinstall: bash perl-base sed grep coreutils debianutils
Preinstall: libc6 libncurses5 libacl1 libattr1
Preinstall: libreadline7 tar gawk dpkg
Preinstall: sysv-rc gzip base-files

# required for preinstall images
Preinstall: perl
Runscripts: base-files initscripts

# preinstall essentials + dependencies
Preinstall: base-files base-passwd bash bsdutils coreutils dash debconf
Preinstall: debianutils diffutils dpkg e2fslibs e2fsprogs findutils gawk
Preinstall: gcc-6-base grep gzip hostname initscripts insserv libacl1
Preinstall: libattr1 libblkid1 libbz2-1.0 libc-bin libc6 libcom-err2 libdb5.3
Preinstall: libgcc1 liblzma5 libmount1 libncurses5 libpam-modules
Preinstall: libpcre3 libsmartcols1 libperl5.26 libdebconfclient0
Preinstall: libpam-modules-bin libpam-runtime libpam0g libreadline7
Preinstall: libselinux1 libsemanage-common libsemanage1 libsepol1 libsigsegv2
Preinstall: libslang2 libss2 libtinfo6 libustr-1.0-1 libuuid1 login lsb-base
Preinstall: mount multiarch-support ncurses-base ncurses-bin passwd perl-base
Preinstall: readline-common sed sensible-utils sysv-rc init-system-helpers sysvinit-utils
Preinstall: tar tzdata util-linux zlib1g xz-utils
VMinstall: util-linux binutils libblkid1 libuuid1 libdevmapper1.02 mount

Runscripts: base-passwd user-setup base-files gawk
Required: autoconf automake binutils bzip2 gcc gettext libc6
Required: libtool libncurses5 perl zlib1g dpkg

VMinstall: libdevmapper1.02.1

Order: user-setup:base-files

# Essential packages (this should also pull the dependencies)
Support: base-files base-passwd bash bsdutils coreutils dash debianutils
Support: diffutils dpkg e2fsprogs findutils grep gzip hostname libc-bin
Support: login mount ncurses-base ncurses-bin perl-base sed init-system-helpers
Support: sysvinit-utils tar util-linux

# Build-essentials
Required: build-essential
Prefer: build-essential:make

# build script needs fakeroot
Support: fakeroot
# lintian support would be nice, but breaks too much atm
#Support: lintian

# helper tools in the chroot
Support: less kmod net-tools procps psmisc strace vim

# everything below same as for Debian:6.0 (apart from the version macros ofc)

# circular dependendencies in openjdk stack
Order: openjdk-6-jre-lib:openjdk-6-jre-headless
Order: openjdk-6-jre-headless:ca-certificates-java
Support: build-essential fakeroot
Support: bison cpio libcrack2 cvs login
Support: file findutils flex diffutils
Support: groff-base gzip info less
Support: make man
Support: net-tools util-linux
Support: patch procps psmisc rcs strace
Support: texinfo unzip vim ncurses-base sysvinit-core

Keep: binutils cpp cracklib file findutils gawk gcc gcc-ada gcc-c++
Keep: gzip libada libstdc++ libunwind
Keep: libunwind-devel libzio make mktemp pam-devel pam-modules
Keep: patch perl rcs timezone

Prefer: cvs libesd0 libfam0 libfam-dev expect

Prefer: gawk locales default-jdk
Prefer: xorg-x11-libs libpng fam mozilla mozilla-nss xorg-x11-Mesa
Prefer: unixODBC libsoup glitz java-1_4_2-sun gnome-panel
Prefer: desktop-data-SuSE gnome2-SuSE mono-nunit gecko-sharp2
Prefer: apache2-prefork openmotif-libs ghostscript-mini gtk-sharp
Prefer: glib-sharp libzypp-zmd-backend mDNSResponder libcom-err2
Prefer: glib-sharp libzypp-zmd-backend mDNSResponder
Prefer: dpkg-dev:make
Prefer: libcomerr2

Prefer: gnome-sharp2:art-sharp2 gnome-sharp:art-sharp
Prefer: ifolder3:gnome-sharp2 ifolder3:gconf-sharp2
Prefer: nautilus-ifolder3:gnome-sharp2
Prefer: gconf-sharp2:glade-sharp2 gconf-sharp:glade-sharp
Prefer: tomboy:gconf-sharp tomboy:gnome-sharp
Prefer: zmd:libzypp-zmd-backend
Prefer: yast2-packagemanager-devel:yast2-packagemanager

Prefer: -libgcc-mainline -libstdc++-mainline -gcc-mainline-c++
Prefer: -libgcj-mainline -viewperf -compat -compat-openssl097g
Prefer: -zmd -OpenOffice_org -pam-laus -libgcc-tree-ssa -busybox-links
Prefer: -crossover-office -libgnutls11-dev

# alternative pkg-config implementation
Prefer: -pkgconf
Prefer: -openrc
Prefer: -file-rc
Prefer: -crossover-office

Conflict: ghostscript-library:ghostscript-mini

#Ignore: sysvinit:initscripts
Ignore: sysvinit:initscripts

Ignore: aaa_base:aaa_skel,suse-release,logrotate,ash,mingetty,distribution-release
Ignore: gettext-devel:libgcj,libstdc++-devel
Expand Down Expand Up @@ -188,15 +160,7 @@ Substitute: java2-devel-packages java-1_4_2-ibm-devel xorg-x11-libs-32bit

Substitute: yast2-devel-packages docbook-xsl-stylesheets doxygen libxslt perl-XML-Writer popt-devel sgml-skel update-desktop-files yast2 yast2-devtools yast2-packagemanager-devel yast2-perl-bindings yast2-testsuite

#
# SUSE compat mappings
#
Substitute: gcc-c++ gcc
Substitute: libsigc++2-devel libsigc++-2.0-dev
Substitute: glibc-devel-32bit
Substitute: pkgconfig pkg-config



%ifarch %ix86
Substitute: kernel-binary-packages kernel-default kernel-smp kernel-bigsmp kernel-debug kernel-um kernel-xen kernel-kdump
Expand All @@ -215,10 +179,10 @@ Substitute: kernel-binary-packages kernel-ppc64 kernel-iseries64
%endif
%ifarch s390
Substitute: kernel-binary-packages kernel-s390
%endif
%enidf
%ifarch s390x
Substitute: kernel-binary-packages kernel-default
%endif
%enidf

%define debian 9999
%define debian_version 9999
Expand Down
9 changes: 0 additions & 9 deletions salt/files/debian_unstable.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,6 @@
<title>Debian Unstable</title>
<description>Debian Unstable Download on Demand release.</description>
<person userid="Admin" role="maintainer"/>
<build>
<disable/>
</build>
<publish>
<disable/>
</publish>
<debuginfo>
<disable/>
</debuginfo>
<repository name="main">
<download arch="x86_64" url="http://deb.debian.org/debian/sid/main" repotype="deb"/>
<arch>x86_64</arch>
Expand Down
5 changes: 4 additions & 1 deletion salt/files/sources.list
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
deb http://httpredir.debian.org/debian stretch main
deb-src http://httpredir.debian.org/debian unstable main
deb-src http://httpredir.debian.org/debian sid main
deb-src http://httpredir.debian.org/debian buster main
deb-src http://httpredir.debian.org/debian jessie main
deb-src http://httpredir.debian.org/debian stretch main
83 changes: 78 additions & 5 deletions salt/obs.sls
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@
- group: root
- mode: 644

/etc/hosts:
file.managed:
- source: salt://files/etc-hosts
- user: root
- group: root
- mode: 644

refresh_packages_db:
cmd.run:
- name: apt-get update -y
Expand Down Expand Up @@ -71,6 +78,34 @@ restart_apache:
- group: root
- mode: 644

/tmp/debian_9.xml:
file.managed:
- source: salt://files/debian_9.xml
- user: root
- group: root
- mode: 644

/tmp/debian_9.conf:
file.managed:
- source: salt://files/debian_9.conf
- user: root
- group: root
- mode: 644

/tmp/debian_testing.xml:
file.managed:
- source: salt://files/debian_testing.xml
- user: root
- group: root
- mode: 644

/tmp/debian_testing.conf:
file.managed:
- source: salt://files/debian_testing.conf
- user: root
- group: root
- mode: 644

/tmp/debian_unstable.xml:
file.managed:
- source: salt://files/debian_unstable.xml
Expand All @@ -92,9 +127,23 @@ restart_apache:
- group: root
- mode: 644

/tmp/test_proj.xml:
/tmp/debian_8_test.xml:
file.managed:
- source: salt://files/debian_8_test.xml
- user: root
- group: root
- mode: 644

/tmp/debian_9_test.xml:
file.managed:
- source: salt://files/test_proj.xml
- source: salt://files/debian_9_test.xml
- user: root
- group: root
- mode: 644

/tmp/debian_testing_test.xml:
file.managed:
- source: salt://files/debian_testing_test.xml
- user: root
- group: root
- mode: 644
Expand All @@ -111,6 +160,22 @@ configure_debian_8_project:
cmd.run:
- name: osc -A https://localhost:443 meta prjconf Debian:8 -F /tmp/debian_8.conf

create_debian_9_project:
cmd.run:
- name: osc -A https://localhost:443 meta prj Debian:9 -F /tmp/debian_9.xml

configure_debian_9_project:
cmd.run:
- name: osc -A https://localhost:443 meta prjconf Debian:9 -F /tmp/debian_9.conf

create_debian_testing_project:
cmd.run:
- name: osc -A https://localhost:443 meta prj Debian:Testing -F /tmp/debian_testing.xml

configure_debian_testing_project:
cmd.run:
- name: osc -A https://localhost:443 meta prjconf Debian:Testing -F /tmp/debian_testing.conf

create_debian_unstable_project:
cmd.run:
- name: osc -A https://localhost:443 meta prj Debian:Unstable -F /tmp/debian_unstable.xml
Expand All @@ -121,9 +186,17 @@ configure_debian_unstable_project:

create_debian_clang_project:
cmd.run:
- name: osc -A https://localhost:443 meta prj debclang -F /tmp/debian_clang.xml
- name: osc -A https://localhost:443 meta prj Debian:Unstable:Clang -F /tmp/debian_clang.xml

create_debian_8_test_project:
cmd.run:
- name: osc -A https://localhost:443 meta prj Debian:8:test -F /tmp/debian_8_test.xml

create_debian_9_test_project:
cmd.run:
- name: osc -A https://localhost:443 meta prj Debian:9:test -F /tmp/debian_9_test.xml

create_test_project:
create_debian_testing_test_project:
cmd.run:
- name: osc -A https://localhost:443 meta prj test -F /tmp/test_proj.xml
- name: osc -A https://localhost:443 meta prj Debian:Testing:test -F /tmp/debian_testing_test.xml

0 comments on commit ec95cb1

Please sign in to comment.