Skip to content

Commit

Permalink
Test build for #949
Browse files Browse the repository at this point in the history
  • Loading branch information
Priyankasaggu11929 authored and SUSE Update Bot committed Mar 8, 2024
1 parent 3e82ee2 commit 20d58e2
Show file tree
Hide file tree
Showing 74 changed files with 3,104 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "daily"
41 changes: 41 additions & 0 deletions .github/workflows/changelog_checker.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
---
name: Check the changelogs

on:
pull_request:

jobs:
changelog-check:
name: changelog check
runs-on: ubuntu-22.04
container: ghcr.io/dcermak/bci-ci:latest

steps:
- uses: actions/checkout@v3
with:
ref: main
fetch-depth: 0

- uses: actions/cache@v3
with:
path: ~/.cache/pypoetry/virtualenvs
key: poetry-${{ hashFiles('poetry.lock') }}

- name: install python dependencies
run: poetry install

- name: fix the file permissions of the repository
run: chown -R $(id -un):$(id -gn) .

- name: fetch all branches
run: git fetch

- name: check the changelog
run: |
poetry run scratch-build-bot \
--os-version SLCI -vvvv \
changelog_check \
--base-ref origin/${{ github.base_ref }} \
--head-ref ${{ github.event.pull_request.head.sha }}
env:
OSC_USER: "irrelevant"
57 changes: 57 additions & 0 deletions .github/workflows/find-missing-packages.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
---
name: Check whether packages are missing on OBS

on:
push:
branches:
- 'SLCI'

jobs:
create-issues-for-dan:
name: create an issue for Dan to create the packages in devel:BCI
runs-on: ubuntu-latest
container: ghcr.io/dcermak/bci-ci:latest

strategy:
fail-fast: false

steps:
# we need all branches for the build checks
- uses: actions/checkout@v3
with:
fetch-depth: 0
ref: main
token: ${{ secrets.CHECKOUT_TOKEN }}

- uses: actions/cache@v3
with:
path: ~/.cache/pypoetry/virtualenvs
key: poetry-${{ hashFiles('poetry.lock') }}

- name: fix the file permissions of the repository
run: chown -R $(id -un):$(id -gn) .

- name: install python dependencies
run: poetry install

- name: find the packages that are missing
run: |
pkgs=$(poetry run scratch-build-bot --os-version SLCI find_missing_packages)
if [[ ${pkgs} = "" ]]; then
echo "missing_pkgs=false" >> $GITHUB_ENV
else
echo "missing_pkgs=true" >> $GITHUB_ENV
echo "pkgs=${pkgs}" >> $GITHUB_ENV
fi
cat test-build.env >> $GITHUB_ENV
env:
OSC_PASSWORD: ${{ secrets.OSC_PASSWORD }}
OSC_USER: "defolos"

- uses: JasonEtco/create-an-issue@v2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
update_existing: true
filename: ".github/create-package.md"
if: env.missing_pkgs == 'true'
116 changes: 116 additions & 0 deletions .obs/workflows.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
---
staging_build:
steps:
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: 389-ds-container
target_project: home:defolos:BCI:CR:SLCI:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: base-image
target_project: home:defolos:BCI:CR:SLCI:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: busybox-image
target_project: home:defolos:BCI:CR:SLCI:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: init-image
target_project: home:defolos:BCI:CR:SLCI:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: mariadb-image
target_project: home:defolos:BCI:CR:SLCI:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: mariadb-client-image
target_project: home:defolos:BCI:CR:SLCI:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: micro-image
target_project: home:defolos:BCI:CR:SLCI:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: minimal-image
target_project: home:defolos:BCI:CR:SLCI:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: nginx-image
target_project: home:defolos:BCI:CR:SLCI:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: postgres-16-image
target_project: home:defolos:BCI:CR:SLCI:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: slci-kernel-module-devel-image
target_project: home:defolos:BCI:CR:SLCI:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: tomcat-10-image
target_project: home:defolos:BCI:CR:SLCI:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLCI
source_package: tomcat-9-image
target_project: home:defolos:BCI:CR:SLCI:Staging
filters:
event: pull_request

refresh_staging_project:
steps:
- trigger_services:
project: home:defolos:BCI:CR:SLCI
package: _project
filters:
event: push
branches:
only:
- SLCI


refresh_devel_BCI:
steps:
- trigger_services:
project: devel:BCI:SLCI
package: 389-ds-container
- trigger_services:
project: devel:BCI:SLCI
package: base-image
- trigger_services:
project: devel:BCI:SLCI
package: busybox-image
- trigger_services:
project: devel:BCI:SLCI
package: init-image
- trigger_services:
project: devel:BCI:SLCI
package: mariadb-image
- trigger_services:
project: devel:BCI:SLCI
package: mariadb-client-image
- trigger_services:
project: devel:BCI:SLCI
package: micro-image
- trigger_services:
project: devel:BCI:SLCI
package: minimal-image
- trigger_services:
project: devel:BCI:SLCI
package: nginx-image
- trigger_services:
project: devel:BCI:SLCI
package: postgres-16-image
- trigger_services:
project: devel:BCI:SLCI
package: slci-kernel-module-devel-image
- trigger_services:
project: devel:BCI:SLCI
package: tomcat-10-image
- trigger_services:
project: devel:BCI:SLCI
package: tomcat-9-image
filters:
event: push
branches:
only:
- SLCI
4 changes: 4 additions & 0 deletions 389-ds-container/389-ds-container.changes
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
-------------------------------------------------------------------
Fri Mar 08 11:01:01 UTC 2024 - SUSE Update Bot <[email protected]>

- First version of the 389 Directory Server BCI
60 changes: 60 additions & 0 deletions 389-ds-container/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# SPDX-License-Identifier: MIT

# Copyright (c) 2024 SUSE LLC

# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon.

# The content of THIS FILE IS AUTOGENERATED and should not be manually modified.
# It is maintained by the BCI team and generated by
# https://github.com/SUSE/BCI-dockerfile-generator

# Please submit bugfixes or comments via https://bugs.opensuse.org/
# You can contact the BCI team via https://github.com/SUSE/bci/discussions


#!BuildTag: suse/389-ds:%%389ds_version%%
#!BuildTag: suse/389-ds:%%389ds_version%%-%RELEASE%
#!BuildTag: suse/389-ds:latest

FROM alp/bci/bci-base:latest

MAINTAINER [email protected]

# Define labels according to https://en.opensuse.org/Building_derived_containers
# labelprefix=com.suse.slci.application.389-ds
LABEL org.opencontainers.image.title="SLCI Project 389 Directory Server"
LABEL org.opencontainers.image.description="389 Directory Server container based on the SUSE Adaptable Linux Platform (ALP)."
LABEL org.opencontainers.image.version="%%389ds_version%%"
LABEL org.opencontainers.image.url="https://susealp.io/"
LABEL org.opencontainers.image.created="%BUILDTIME%"
LABEL org.opencontainers.image.vendor="SUSE LLC"
LABEL org.opencontainers.image.source="%SOURCEURL%"
LABEL io.artifacthub.package.readme-url="%SOURCEURL%/README.md"
LABEL org.opensuse.reference="registry.suse.com/suse/389-ds:%%389ds_version%%-%RELEASE%"
LABEL org.openbuildservice.disturl="%DISTURL%"
LABEL com.suse.supportlevel="l3"
LABEL com.suse.eula="sle-bci"
LABEL com.suse.lifecycle-url="https://www.suse.com/lifecycle"
LABEL com.suse.release-stage="beta"
# endlabelprefix

RUN set -euo pipefail; zypper -n in --no-recommends 389-ds timezone openssl nss_synth; zypper -n clean; rm -rf /var/log/*
CMD ["/usr/lib/dirsrv/dscontainer", "-r"]
EXPOSE 3389 3636

COPY nsswitch.conf /etc/nsswitch.conf

RUN set -euo pipefail; mkdir -p /data/config; \
mkdir -p /data/ssca; \
mkdir -p /data/run; \
mkdir -p /var/run/dirsrv; \
ln -s /data/config /etc/dirsrv/slapd-localhost; \
ln -s /data/ssca /etc/dirsrv/ssca; \
ln -s /data/run /var/run/dirsrv

HEALTHCHECK --start-period=5m --timeout=5s --interval=5s --retries=2 \
CMD /usr/lib/dirsrv/dscontainer -H

VOLUME /data
3 changes: 3 additions & 0 deletions 389-ds-container/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# The SLCI Project 389 Directory Server Container image

389 Directory Server container based on the SUSE Adaptable Linux Platform (ALP).
10 changes: 10 additions & 0 deletions 389-ds-container/_service
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<services>
<service mode="buildtime" name="docker_label_helper"/>
<service mode="buildtime" name="kiwi_metainfo_helper"/>
<service name="replace_using_package_version" mode="buildtime">
<param name="file">Dockerfile</param>
<param name="regex">%%389ds_version%%</param>
<param name="package">389-ds</param>
<param name="parse-version">minor</param>
</service>
</services>
22 changes: 22 additions & 0 deletions 389-ds-container/nsswitch.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
passwd: compat synth
group: compat synth
shadow: compat
# Allow initgroups to default to the setting for group.
# initgroups: compat

hosts: files dns
networks: files dns

aliases: files usrfiles
ethers: files usrfiles
gshadow: files usrfiles
netgroup: files nis
protocols: files usrfiles
publickey: files
rpc: files usrfiles
services: files usrfiles

automount: files nis
bootparams: files
netmasks: files

3 changes: 3 additions & 0 deletions _config
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
<status code="unknown_project">
<summary>Project not found: devel:BCI:SLCI</summary>
</status>
3 changes: 3 additions & 0 deletions base-image/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# The SLCI Project BCI Base Container image

Base container based on the SUSE Adaptable Linux Platform (ALP).
4 changes: 4 additions & 0 deletions base-image/_service
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<services>
<service mode="buildtime" name="kiwi_label_helper"/>
<service mode="buildtime" name="kiwi_metainfo_helper"/>
</services>
4 changes: 4 additions & 0 deletions base-image/base-image.changes
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
-------------------------------------------------------------------
Fri Mar 08 11:01:01 UTC 2024 - SUSE Update Bot <[email protected]>

- First version of the Base BCI
Loading

0 comments on commit 20d58e2

Please sign in to comment.