Skip to content

Commit

Permalink
Merge pull request #1967 from SUSE/for-deploy-6
Browse files Browse the repository at this point in the history
🤖: Update build recipes for SP6
  • Loading branch information
dirkmueller authored Nov 7, 2024
2 parents cdeca8b + 87f4d2a commit 7446f12
Show file tree
Hide file tree
Showing 17 changed files with 394 additions and 36 deletions.
30 changes: 22 additions & 8 deletions .obs/workflows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,14 @@ staging_build:
source_project: home:defolos:BCI:CR:SLE-15-SP6
source_package: sac-apache-tomcat-10-image
target_project: home:defolos:BCI:CR:SLE-15-SP6:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLE-15-SP6
source_package: sac-apache-tomcat-9-image
target_project: home:defolos:BCI:CR:SLE-15-SP6:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLE-15-SP6
source_package: sac-apache-tomcat-9-image
target_project: home:defolos:BCI:CR:SLE-15-SP6:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLE-15-SP6
source_package: base-fips-image
Expand Down Expand Up @@ -71,19 +79,19 @@ staging_build:
target_project: home:defolos:BCI:CR:SLE-15-SP6:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLE-15-SP6
source_package: golang-oldstable-openssl-image
source_package: golang-oldstable-image
target_project: home:defolos:BCI:CR:SLE-15-SP6:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLE-15-SP6
source_package: golang-stable-openssl-image
source_package: golang-oldstable-openssl-image
target_project: home:defolos:BCI:CR:SLE-15-SP6:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLE-15-SP6
source_package: golang-oldstable-image
source_package: golang-stable-image
target_project: home:defolos:BCI:CR:SLE-15-SP6:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLE-15-SP6
source_package: golang-stable-image
source_package: golang-stable-openssl-image
target_project: home:defolos:BCI:CR:SLE-15-SP6:Staging
- branch_package:
source_project: home:defolos:BCI:CR:SLE-15-SP6
Expand Down Expand Up @@ -245,6 +253,12 @@ refresh_devel_BCI:
- trigger_services:
project: devel:BCI:SLE-15-SP6
package: sac-apache-tomcat-10-image
- trigger_services:
project: devel:BCI:SLE-15-SP6
package: sac-apache-tomcat-9-image
- trigger_services:
project: devel:BCI:SLE-15-SP6
package: sac-apache-tomcat-9-image
- trigger_services:
project: devel:BCI:SLE-15-SP6
package: base-fips-image
Expand Down Expand Up @@ -283,16 +297,16 @@ refresh_devel_BCI:
package: git-image
- trigger_services:
project: devel:BCI:SLE-15-SP6
package: golang-oldstable-openssl-image
package: golang-oldstable-image
- trigger_services:
project: devel:BCI:SLE-15-SP6
package: golang-stable-openssl-image
package: golang-oldstable-openssl-image
- trigger_services:
project: devel:BCI:SLE-15-SP6
package: golang-oldstable-image
package: golang-stable-image
- trigger_services:
project: devel:BCI:SLE-15-SP6
package: golang-stable-image
package: golang-stable-openssl-image
- trigger_services:
project: devel:BCI:SLE-15-SP6
package: grafana-image
Expand Down
10 changes: 5 additions & 5 deletions golang-oldstable-openssl-image/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,22 @@
#!BuildTag: bci/golang:oldstable-openssl
#!BuildTag: bci/golang:%%golang_version%%-openssl-%RELEASE%
#!BuildTag: bci/golang:%%golang_version%%-openssl
#!BuildTag: bci/golang:1.20-openssl
#!BuildTag: bci/golang:1.22-openssl
#!BuildName: bci-golang-oldstable-openssl
#!BuildVersion: 15.6
#!BuildRelease: 33
FROM registry.suse.com/bci/bci-base:15.6

RUN set -euo pipefail; \
zypper -n install --no-recommends go1.20-openssl go1.20-openssl-doc make curl findutils gawk git-core procps lifecycle-data-sle-module-development-tools; \
zypper -n install --no-recommends go1.22-openssl go1.22-openssl-doc make curl findutils gawk git-core procps lifecycle-data-sle-module-development-tools; \
zypper -n clean; \
rm -rf {/target,}/var/log/{alternatives.log,lastlog,tallylog,zypper.log,zypp/history,YaST2}

# Define labels according to https://en.opensuse.org/Building_derived_containers
# labelprefix=com.suse.bci.golang
LABEL org.opencontainers.image.authors="https://github.com/SUSE/bci/discussions"
LABEL org.opencontainers.image.title="SLE BCI Go 1.20-openssl development"
LABEL org.opencontainers.image.description="Go 1.20-openssl development container based on the SLE Base Container Image."
LABEL org.opencontainers.image.title="SLE BCI Go 1.22-openssl development"
LABEL org.opencontainers.image.description="Go 1.22-openssl development container based on the SLE Base Container Image."
LABEL org.opencontainers.image.version="%%golang_version%%-openssl"
LABEL org.opencontainers.image.url="https://www.suse.com/products/base-container-images/"
LABEL org.opencontainers.image.created="%BUILDTIME%"
Expand All @@ -59,7 +59,7 @@ ENV PATH="/go/bin:/usr/local/go/bin:/root/go/bin/:/usr/local/sbin:/usr/local/bin

# only available on go's tsan_arch architectures
#!ArchExclusiveLine: x86_64 aarch64 s390x ppc64le
RUN set -euo pipefail; if zypper -n install go1.20-openssl-race; then zypper -n clean; fi
RUN set -euo pipefail; if zypper -n install go1.22-openssl-race; then zypper -n clean; fi
RUN set -euo pipefail; install -m 755 -d /go/bin /go/src
RUN set -euo pipefail; rm -rf {/target,}/var/log/{alternatives.log,lastlog,tallylog,zypper.log,zypp/history,YaST2}
WORKDIR /go
Expand Down
16 changes: 8 additions & 8 deletions golang-oldstable-openssl-image/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Go 1.20-openssl development container image
# Go 1.22-openssl development container image

![Redistributable](https://img.shields.io/badge/Redistributable-Yes-green)[![SLSA](https://img.shields.io/badge/SLSA_(v1.0)-Build_L3-Green)](https://documentation.suse.com/sbp/server-linux/html/SBP-SLSA4/)
[![Provenance: Available](https://img.shields.io/badge/Provenance-Available-Green)](https://documentation.suse.com/container/all/html/Container-guide/index.html#container-verify)
Expand Down Expand Up @@ -41,8 +41,8 @@ the following Dockerfile options.
### Building from `scratch`

```Dockerfile
# Build the application using the Go 1.20-openssl development container image
FROM registry.suse.com/bci/golang:1.20-openssl as build
# Build the application using the Go 1.22-openssl development container image
FROM registry.suse.com/bci/golang:1.22-openssl as build

WORKDIR /app

Expand Down Expand Up @@ -80,13 +80,13 @@ There are situations when you don't want to run an application inside a containe
To compile the application, without running it inside a container instance, use the following command:

```ShellSession
$ podman run --rm -v "$PWD":/app:Z -w /app registry.suse.com/bci/golang:1.20-openssl go build -v
$ podman run --rm -v "$PWD":/app:Z -w /app registry.suse.com/bci/golang:1.22-openssl go build -v
```

To run the application tests inside a container, use the following command:

```ShellSession
$ podman run --rm -v "$PWD":/app:Z -w /app registry.suse.com/bci/golang:1.20-openssl go test -v
$ podman run --rm -v "$PWD":/app:Z -w /app registry.suse.com/bci/golang:1.22-openssl go test -v
```


Expand All @@ -96,8 +96,8 @@ The [SLE BCI General Purpose Base Containers](https://opensource.suse.com/bci-do
images offer four different options for deployment, depending on your exact requirements.

```Dockerfile
# Build the application using the Go 1.20-openssl development Container Image
FROM registry.suse.com/bci/golang:1.20-openssl as build
# Build the application using the Go 1.22-openssl development Container Image
FROM registry.suse.com/bci/golang:1.22-openssl as build

WORKDIR /app

Expand Down Expand Up @@ -138,7 +138,7 @@ import _ "crypto/tls/fipsonly"
In addition to the standard SLE BCI development packages, the following tools
are included in the image:

- go1.20-openssl-race
- go1.22-openssl-race
- make

## Licensing
Expand Down
2 changes: 1 addition & 1 deletion golang-oldstable-openssl-image/_service
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
<service name="replace_using_package_version" mode="buildtime">
<param name="file">Dockerfile</param>
<param name="regex">%%golang_version%%</param>
<param name="package">go1.20-openssl</param>
<param name="package">go1.22-openssl</param>
</service>
</services>
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
-------------------------------------------------------------------
Thu Nov 7 14:17:21 UTC 2024 - SUSE Update Bot <[email protected]>

- oldstable updated to 1.22; stable is now 1.23

-------------------------------------------------------------------
Wed Oct 30 15:35:19 UTC 2024 - SUSE Update Bot <[email protected]>

Expand Down
10 changes: 5 additions & 5 deletions golang-stable-openssl-image/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,23 +19,23 @@
#!BuildTag: bci/golang:stable-openssl
#!BuildTag: bci/golang:%%golang_version%%-openssl-%RELEASE%
#!BuildTag: bci/golang:%%golang_version%%-openssl
#!BuildTag: bci/golang:1.21-openssl
#!BuildTag: bci/golang:1.23-openssl
#!BuildTag: bci/golang:latest
#!BuildName: bci-golang-stable-openssl
#!BuildVersion: 15.6
#!BuildRelease: 33
FROM registry.suse.com/bci/bci-base:15.6

RUN set -euo pipefail; \
zypper -n install --no-recommends go1.21-openssl go1.21-openssl-doc make curl findutils gawk git-core procps lifecycle-data-sle-module-development-tools; \
zypper -n install --no-recommends go1.23-openssl go1.23-openssl-doc make curl findutils gawk git-core procps lifecycle-data-sle-module-development-tools; \
zypper -n clean; \
rm -rf {/target,}/var/log/{alternatives.log,lastlog,tallylog,zypper.log,zypp/history,YaST2}

# Define labels according to https://en.opensuse.org/Building_derived_containers
# labelprefix=com.suse.bci.golang
LABEL org.opencontainers.image.authors="https://github.com/SUSE/bci/discussions"
LABEL org.opencontainers.image.title="SLE BCI Go 1.21-openssl development"
LABEL org.opencontainers.image.description="Go 1.21-openssl development container based on the SLE Base Container Image."
LABEL org.opencontainers.image.title="SLE BCI Go 1.23-openssl development"
LABEL org.opencontainers.image.description="Go 1.23-openssl development container based on the SLE Base Container Image."
LABEL org.opencontainers.image.version="%%golang_version%%-openssl"
LABEL org.opencontainers.image.url="https://www.suse.com/products/base-container-images/"
LABEL org.opencontainers.image.created="%BUILDTIME%"
Expand All @@ -60,7 +60,7 @@ ENV PATH="/go/bin:/usr/local/go/bin:/root/go/bin/:/usr/local/sbin:/usr/local/bin

# only available on go's tsan_arch architectures
#!ArchExclusiveLine: x86_64 aarch64 s390x ppc64le
RUN set -euo pipefail; if zypper -n install go1.21-openssl-race; then zypper -n clean; fi
RUN set -euo pipefail; if zypper -n install go1.23-openssl-race; then zypper -n clean; fi
RUN set -euo pipefail; install -m 755 -d /go/bin /go/src
RUN set -euo pipefail; rm -rf {/target,}/var/log/{alternatives.log,lastlog,tallylog,zypper.log,zypp/history,YaST2}
WORKDIR /go
Expand Down
16 changes: 8 additions & 8 deletions golang-stable-openssl-image/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Go 1.21-openssl development container image
# Go 1.23-openssl development container image

![Redistributable](https://img.shields.io/badge/Redistributable-Yes-green)[![SLSA](https://img.shields.io/badge/SLSA_(v1.0)-Build_L3-Green)](https://documentation.suse.com/sbp/server-linux/html/SBP-SLSA4/)
[![Provenance: Available](https://img.shields.io/badge/Provenance-Available-Green)](https://documentation.suse.com/container/all/html/Container-guide/index.html#container-verify)
Expand Down Expand Up @@ -41,8 +41,8 @@ the following Dockerfile options.
### Building from `scratch`

```Dockerfile
# Build the application using the Go 1.21-openssl development container image
FROM registry.suse.com/bci/golang:1.21-openssl as build
# Build the application using the Go 1.23-openssl development container image
FROM registry.suse.com/bci/golang:1.23-openssl as build

WORKDIR /app

Expand Down Expand Up @@ -80,13 +80,13 @@ There are situations when you don't want to run an application inside a containe
To compile the application, without running it inside a container instance, use the following command:

```ShellSession
$ podman run --rm -v "$PWD":/app:Z -w /app registry.suse.com/bci/golang:1.21-openssl go build -v
$ podman run --rm -v "$PWD":/app:Z -w /app registry.suse.com/bci/golang:1.23-openssl go build -v
```

To run the application tests inside a container, use the following command:

```ShellSession
$ podman run --rm -v "$PWD":/app:Z -w /app registry.suse.com/bci/golang:1.21-openssl go test -v
$ podman run --rm -v "$PWD":/app:Z -w /app registry.suse.com/bci/golang:1.23-openssl go test -v
```


Expand All @@ -96,8 +96,8 @@ The [SLE BCI General Purpose Base Containers](https://opensource.suse.com/bci-do
images offer four different options for deployment, depending on your exact requirements.

```Dockerfile
# Build the application using the Go 1.21-openssl development Container Image
FROM registry.suse.com/bci/golang:1.21-openssl as build
# Build the application using the Go 1.23-openssl development Container Image
FROM registry.suse.com/bci/golang:1.23-openssl as build

WORKDIR /app

Expand Down Expand Up @@ -138,7 +138,7 @@ import _ "crypto/tls/fipsonly"
In addition to the standard SLE BCI development packages, the following tools
are included in the image:

- go1.21-openssl-race
- go1.23-openssl-race
- make

## Licensing
Expand Down
2 changes: 1 addition & 1 deletion golang-stable-openssl-image/_service
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
<service name="replace_using_package_version" mode="buildtime">
<param name="file">Dockerfile</param>
<param name="regex">%%golang_version%%</param>
<param name="package">go1.21-openssl</param>
<param name="package">go1.23-openssl</param>
</service>
</services>
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
-------------------------------------------------------------------
Thu Nov 7 14:17:21 UTC 2024 - SUSE Update Bot <[email protected]>

- oldstable updated to 1.22; stable is now 1.23

-------------------------------------------------------------------
Wed Oct 30 15:35:19 UTC 2024 - SUSE Update Bot <[email protected]>

Expand Down
6 changes: 6 additions & 0 deletions sac-apache-tomcat-9-image/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!ExclusiveArch: do-not-build
#!ForceMultiVersion
#!BuildVersion: workaround-for-an-obs-bug
#!BuildRelease: 55

# For this container we only build the Dockerfile.$flavor builds.
76 changes: 76 additions & 0 deletions sac-apache-tomcat-9-image/Dockerfile.openjdk11
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# 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

#!UseOBSRepositories
#!ExclusiveArch: aarch64 x86_64
#!BuildTag: containers/apache-tomcat:%%tomcat_version%%-openjdk11-%RELEASE%
#!BuildTag: containers/apache-tomcat:%%tomcat_version%%-openjdk11
#!BuildTag: containers/apache-tomcat:9-openjdk11
#!ForceMultiVersion
#!BuildName: containers-apache-tomcat-9-openjdk11
#!BuildVersion: %%tomcat_version%%
#!BuildRelease: 55
FROM registry.suse.com/bci/bci-micro:15.6 AS target
FROM bci/bci-base:15.6 AS builder
COPY --from=target / /target

RUN set -euo pipefail; \
zypper -n --installroot /target --gpg-auto-import-keys install --no-recommends tomcat curl sed java-11-openjdk java-11-openjdk-headless; \
zypper -n --installroot /target remove util-linux; \
zypper -n clean; \
rm -rf {/target,}/var/log/{alternatives.log,lastlog,tallylog,zypper.log,zypp/history,YaST2}
FROM registry.suse.com/bci/bci-micro:15.6
COPY --from=builder /target /
# Define labels according to https://en.opensuse.org/Building_derived_containers
# labelprefix=com.suse.application.apache-tomcat
LABEL org.opencontainers.image.authors=""
LABEL org.opencontainers.image.title="Apache Tomcat"
LABEL org.opencontainers.image.description="The Apache Tomcat software is an open-source implementation of the Jakarta Servlet, Jakarta Pages, Jakarta Expression Language, Jakarta WebSocket, Jakarta Annotations, and Jakarta Authentication specifications. These specifications are part of the Jakarta EE platform."
LABEL org.opencontainers.image.version="%%tomcat_version%%"
LABEL org.opencontainers.image.url="https://apps.rancher.io/applications/apache-tomcat"
LABEL org.opencontainers.image.created="%BUILDTIME%"
LABEL org.opencontainers.image.vendor="SUSE LLC"
LABEL org.opencontainers.image.source="%SOURCEURL%"
LABEL org.opencontainers.image.ref.name="%%tomcat_version%%-openjdk11-%RELEASE%"
LABEL org.opensuse.reference="dp.apps.rancher.io/containers/apache-tomcat:%%tomcat_version%%-openjdk11-%RELEASE%"
LABEL org.openbuildservice.disturl="%DISTURL%"
LABEL com.suse.supportlevel="techpreview"
LABEL com.suse.supportlevel.until="2026-12-31"
LABEL com.suse.eula="sle-eula"
LABEL com.suse.lifecycle-url="https://www.suse.com/lifecycle#suse-linux-enterprise-server-15"
LABEL com.suse.release-stage="released"
# endlabelprefix
LABEL org.opencontainers.image.base.name="%BASE_REFNAME%"
LABEL org.opencontainers.image.base.digest="%BASE_DIGEST%"
LABEL io.artifacthub.package.readme-url="%SOURCEURL%/README.openjdk11.md"
LABEL io.artifacthub.package.logo-url="https://tomcat.apache.org/res/images/tomcat.png"
ENV TOMCAT_MAJOR="9"
ENV TOMCAT_VERSION="%%tomcat_version%%"
ENV CATALINA_HOME="/usr/share/tomcat"
ENV CATALINA_BASE="/usr/share/tomcat"
ENV PATH="/usr/share/tomcat/bin:$PATH"

CMD ["/usr/lib/tomcat/server", "start"]
EXPOSE 8080/tcp
RUN set -euo pipefail; mkdir -p /var/log/tomcat; chown --recursive tomcat:tomcat /var/log/tomcat
RUN set -euo pipefail; ln -s /usr/share/tomcat /usr/local/tomcat
RUN set -euo pipefail; \
sed -i /etc/tomcat/logging.properties \
-e 's|org\.apache\.catalina\.core\.ContainerBase\.\[Catalina\]\.\[localhost\]\.handlers =.*|org.apache.catalina.core.ContainerBase.[Catalina].[localhost].handlers = java.util.logging.ConsoleHandler|' \
-e 's|org\.apache\.catalina\.core\.ContainerBase\.\[Catalina\]\.\[localhost\]\.\[/manager\]\.handlers =.*|org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager].handlers = java.util.logging.ConsoleHandler|' \
-e 's|org\.apache\.catalina\.core\.ContainerBase\.\[Catalina\]\.\[localhost\]\.\[/host-manager\]\.handlers =.*|org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/host-manager].handlers = java.util.logging.ConsoleHandler|'

WORKDIR $CATALINA_HOME
USER tomcat
Loading

0 comments on commit 7446f12

Please sign in to comment.