1
0

Accepting request 1070435 from home:psaggu

initial package for coredns version 1.9.3 w.r.t k8s1.25

OBS-URL: https://build.opensuse.org/request/show/1070435
OBS-URL: https://build.opensuse.org/package/show/devel:kubic/coredns-for-k8s1.25?expand=0&rev=1
This commit is contained in:
Richard Brown 2023-03-10 15:53:30 +00:00 committed by Git OBS Bridge
commit 618e985a23
10 changed files with 236 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
.osc

35
Corefile Normal file
View File

@ -0,0 +1,35 @@
#
# Example configuration file for coredns.
#
# All zones
. {
# Bind on a specific IP
bind 127.0.0.1
# Forward queries for all zones to a resolver using TLS
# forward . tls://1.1.1.1:853 tls://1.0.0.1:853
# Forward queries for all zones to a resolver using plain ol' DNS
#forward . dns://8.8.8.8:53
# Forward queries for all zones to /etc/resolv.conf
forward . /etc/resolv.conf
# Errors related to query processing are printed to STDOUT
errors
# Log all DNS queries
#log
# Extra debug information
# debug
# Resolve hostsnames specified in /etc/hosts
hosts {
fallthrough
}
}
# Import Zone configurations from other files
# import AdditonalZones.conf

20
_service Normal file
View File

@ -0,0 +1,20 @@
<services>
<service name="tar_scm" mode="disabled">
<param name="url">https://github.com/coredns/coredns</param>
<param name="scm">git</param>
<param name="exclude">.git</param>
<param name="revision">v1.9.3</param>
<param name="versionformat">@PARENT_TAG@</param>
<param name="versionrewrite-pattern">v(.*)</param>
<param name="changesgenerate">enable</param>
</service>
<service mode="disabled" name="set_version">
</service>
<service name="recompress" mode="disabled">
<param name="file">*.tar</param>
<param name="compression">gz</param>
</service>
<service name="go_modules" mode="disabled">
<param name="archive">coredns-1.9.3.tar.gz</param>
</service>
</services>

4
_servicedata Normal file
View File

@ -0,0 +1,4 @@
<servicedata>
<service name="tar_scm">
<param name="url">https://github.com/coredns/coredns</param>
<param name="changesrevision">45b0a11294c59bfd806a57807aaa2a185f761cd5</param></service></servicedata>

3
coredns-1.9.3.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:3eb1fe6468cbdb8cd722818ec7bfb1d15d26e9dc8348751cf3bf21f47eb530ac
size 640270

View File

@ -0,0 +1,5 @@
-------------------------------------------------------------------
Thu Mar 9 13:55:12 UTC 2023 - Priyanka Saggu <priyanka.saggu@suse.com>
- Initial package version 1.9.3
* Version specified in kubernetes-1.25 build/dependencies.yaml

130
coredns-for-k8s1.25.spec Normal file
View File

@ -0,0 +1,130 @@
#
# spec file for package coredns-for-k8s1.24
#
# Copyright (c) 2021 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 license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define project github.com/coredns/coredns
Name: coredns-for-k8s1.25
Version: 1.9.3
Release: 0
Summary: DNS server written in Go
License: Apache-2.0
Group: Productivity/Networking/DNS/Servers
URL: https://coredns.io
Provides: dns_daemon
Source0: coredns-%{version}.tar.gz
Source1: vendor.tar.gz
Source10: Corefile
Source11: coredns.service
BuildRequires: fdupes
BuildRequires: golang(API) >= 1.19
Conflicts: coredns
Provides: coredns-for-k8s = %{version}
Conflicts: coredns-for-k8s
%description
CoreDNS is a DNS server in Go. It has a plugin architecture for
extending it.
CoreDNS can listen for DNS request coming in over UDP/TCP (RFC 1035),
TLS (RFC 7858) and gRPC (not a standard).
%package extras
Summary: Extra components for the coredns package
Group: Productivity/Networking/DNS/Servers
Requires: coredns-for-k8s1.24 = %{version}
Supplements: coredns-for-k8s1.24
BuildArch: noarch
BuildRequires: pkgconfig(systemd)
Conflicts: coredns-extras
Provides: coredns-extras-for-k8s = %{version}
Conflicts: coredns-extras-for-k8s
%description extras
Extra components for the coredns package, to make coredns usable in a
non-containerized environment (man pages, configuration, unit file).
%prep
%setup -q -a1 -n coredns-%{version}
%build
# We can't use symlinks here because go-list gets confused by symlinks, so we
# have to copy the source to $HOME/go and then use that as the GOPATH.
export GOPATH=$HOME/go
export PATH=$PATH:$GOPATH/bin
rm -rf $HOME/go/src
mkdir -pv $HOME/go/src/%{project}
find . -mindepth 1 -maxdepth 1 -exec cp -r {} $HOME/go/src/%{project} \;
cd $HOME/go/src/%{project}
go build -mod=vendor -v -buildmode=pie -o coredns
%check
# Too many tests fail due to the restricted permissions in the build enviroment.
# Updates must be tested manually.
%install
cd $HOME/go/src/%{project}
# Binaries
install -D -m 0755 coredns %{buildroot}%{_sbindir}/coredns
ln -s service %{buildroot}%{_sbindir}/rccoredns
# Configuration
install -D -m 0644 %{SOURCE10} %{buildroot}%{_sysconfdir}/coredns/Corefile
# systemd service
install -D -m 0644 %{SOURCE11} %{buildroot}%{_unitdir}/coredns.service
# Manpages
install -d %{buildroot}/%{_mandir}/man1
install -m 0644 man/coredns*.1 %{buildroot}/%{_mandir}/man1
install -d %{buildroot}/%{_mandir}/man5
install -m 0644 man/corefile*.5 %{buildroot}/%{_mandir}/man5
install -d %{buildroot}/%{_mandir}/man7
install -m 0644 man/coredns-*.7 %{buildroot}/%{_mandir}/man7
%fdupes %{buildroot}/%{_prefix}
%pre extras
%service_add_pre coredns.service
%post extras
%service_add_post coredns.service
%{fillup_only -n coredns}
%preun extras
%service_del_preun coredns.service
%postun extras
%service_del_postun coredns.service
%files
# Binaries
%{_sbindir}/coredns
# License
%license LICENSE
%files extras
%{_sbindir}/rccoredns
# Manpages
%{_mandir}/man1/coredns*
%{_mandir}/man5/corefile*
%{_mandir}/man7/coredns-*
# Configs
%dir %{_sysconfdir}/coredns
%config(noreplace) %{_sysconfdir}/coredns/Corefile
%{_unitdir}/coredns.service
%changelog

12
coredns.service Normal file
View File

@ -0,0 +1,12 @@
[Unit]
Description=Fast and flexible DNS server
After=network-online.target
Wants=network-online.target
Documentation=man:coredns(1)
[Service]
Type=simple
ExecStart=/usr/sbin/coredns -conf /etc/coredns/Corefile -pidfile /var/run/coredns.pid
[Install]
WantedBy=multi-user.target

3
vendor.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:9dc2782512fdae99d1c14633e3aeef157bc89364f7c084fb14f22c792a89cc0d
size 9009524