Compare commits
6 Commits
Author | SHA256 | Date | |
---|---|---|---|
|
e7dfee0ca9 | ||
|
de720e7e22 | ||
|
210cf5ea5f | ||
|
7b0bc56119 | ||
|
5d18d2e612 | ||
1912d74762 |
2
_service
2
_service
@ -3,7 +3,7 @@
|
|||||||
<param name="url">https://github.com/etcd-io/etcd.git</param>
|
<param name="url">https://github.com/etcd-io/etcd.git</param>
|
||||||
<param name="scm">git</param>
|
<param name="scm">git</param>
|
||||||
<param name="exclude">.git</param>
|
<param name="exclude">.git</param>
|
||||||
<param name="revision">v3.5.12</param>
|
<param name="revision">v3.5.18</param>
|
||||||
<param name="versionformat">@PARENT_TAG@</param>
|
<param name="versionformat">@PARENT_TAG@</param>
|
||||||
<param name="changesgenerate">enable</param>
|
<param name="changesgenerate">enable</param>
|
||||||
<param name="versionrewrite-pattern">v(.*)</param>
|
<param name="versionrewrite-pattern">v(.*)</param>
|
||||||
|
@ -5,4 +5,4 @@
|
|||||||
<param name="url">git://github.com/etcd-io/etcd.git</param>
|
<param name="url">git://github.com/etcd-io/etcd.git</param>
|
||||||
<param name="changesrevision">99018a77bea9a9d29962e5169876c64e02739c52</param></service><service name="tar_scm">
|
<param name="changesrevision">99018a77bea9a9d29962e5169876c64e02739c52</param></service><service name="tar_scm">
|
||||||
<param name="url">https://github.com/etcd-io/etcd.git</param>
|
<param name="url">https://github.com/etcd-io/etcd.git</param>
|
||||||
<param name="changesrevision">e7b3bb6ccac840770f108ef9a0f013fa51b83256</param></service></servicedata>
|
<param name="changesrevision">5bca08ec10d2ffcc658a5002381a3e5600d7132f</param></service></servicedata>
|
@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:de10f81bb463e1e057d3a76eaf252c360e5b2b082f2b646539b1ab6e1509d84e
|
|
||||||
size 4138338
|
|
3
etcd-3.5.18.tar.gz
Normal file
3
etcd-3.5.18.tar.gz
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:edc25d80acd2342737b44886f4f279b84a5e61a1d815105a9e2ba9c6015999cf
|
||||||
|
size 4185838
|
91
etcd.changes
91
etcd.changes
@ -1,3 +1,94 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Jan 27 10:25:07 UTC 2025 - Elisei Roca <eroca@suse.com>
|
||||||
|
|
||||||
|
- Update to version 3.5.18:
|
||||||
|
* Ensure all goroutines created by StartEtcd to exit before
|
||||||
|
closing the errc
|
||||||
|
* mvcc: restore tombstone index if it's first revision
|
||||||
|
* Bump go toolchain to 1.22.11
|
||||||
|
* Avoid deadlock in etcd.Close when stopping during bootstrapping
|
||||||
|
* etcdutl/etcdutl: use datadir package to build wal/snapdir
|
||||||
|
* Remove duplicated <-s.ReadyNotify()
|
||||||
|
* Do not wait for ready notify if the server is stopping
|
||||||
|
* Fix mixVersion test case: ensure a snapshot to be sent out
|
||||||
|
* *: support custom content check offline in v2store
|
||||||
|
* Print warning message for deprecated flags if set
|
||||||
|
* fix runtime error: comparing uncomparable type
|
||||||
|
* add tls min/max version to grpc proxy
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Dec 2 13:37:55 UTC 2024 - Marcus Rueckert <mrueckert@suse.de>
|
||||||
|
|
||||||
|
- Fixing a configuration data loss bug:
|
||||||
|
Fillup really really wants that the template and the target file
|
||||||
|
actually follow the sysconfig format. The current config and the
|
||||||
|
current template do not fulfill this requirement.
|
||||||
|
|
||||||
|
Move the current /etc/sysconfig/etcd to /etc/default/etcd and
|
||||||
|
install a new sysconfig file which only adds the ETCD_OPTIONS
|
||||||
|
option, which is actually used by the unit file.
|
||||||
|
|
||||||
|
This also makes it a bit cleaner to move etcd to use
|
||||||
|
--config-file in the long run.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Sun Dec 1 14:52:01 UTC 2024 - Elisei Roca <eroca@suse.com>
|
||||||
|
|
||||||
|
- Update etcd configuration file based on
|
||||||
|
https://github.com/etcd-io/etcd/blob/v3.5.17/etcd.conf.yml.sample
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Nov 29 13:36:47 UTC 2024 - Elisei Roca <eroca@suse.com>
|
||||||
|
|
||||||
|
- Update to version 3.5.17:
|
||||||
|
* fix(defrag): close temp file in case of error
|
||||||
|
* Bump go toolchain to 1.22.9
|
||||||
|
* fix(defrag): handle defragdb failure
|
||||||
|
* fix(defrag): handle no space left error
|
||||||
|
* [3.5] Fix risk of a partial write txn being applied
|
||||||
|
* [serverWatchStream] terminate recvLoop on sws.close()
|
||||||
|
|
||||||
|
- Update to version 3.5.16:
|
||||||
|
* Bump go toolchain to 1.22.7
|
||||||
|
* Introduce compaction sleep interval flag
|
||||||
|
* Fix passing default grpc call options in Kubernetes client
|
||||||
|
* Skip leadership check if the etcd instance is active processing
|
||||||
|
heartbeats
|
||||||
|
* Introduce Kubernetes KV interface to etcd client
|
||||||
|
|
||||||
|
- Update to version 3.5.15:
|
||||||
|
* Differentiate the warning message for rejected client and peer
|
||||||
|
* connections
|
||||||
|
* Suppress noisy basic auth token deletion log
|
||||||
|
* Support multiple values for allowed client and peer TLS
|
||||||
|
identities(#18015)
|
||||||
|
* print error log when validation on conf change failed
|
||||||
|
|
||||||
|
- Update to version 3.5.14:
|
||||||
|
* etcdutl: Fix snapshot restore memory alloc issue
|
||||||
|
* server: Implement WithMmapSize option for backend config
|
||||||
|
* gRPC health server sets serving status to NOT_SERVING on defrag
|
||||||
|
* server/mvcc: introduce compactBeforeSetFinishedCompact
|
||||||
|
failpoint
|
||||||
|
* Update the compaction log when bootstrap and update compact's
|
||||||
|
signature
|
||||||
|
* add experimental-snapshot-catchup-entries flag.
|
||||||
|
* Fix retry requests when receiving ErrGPRCNotSupportedForLearner
|
||||||
|
|
||||||
|
- Update to version 3.5.13:
|
||||||
|
* Fix progress notification for watch that doesn't get any events
|
||||||
|
* pkg/types: Support Unix sockets in NewURLS
|
||||||
|
* added arguments to the grpc-proxy: dial-keepalive-time,
|
||||||
|
dial-keepalive-timeout, permit-without-stream
|
||||||
|
* server: fix comment to match function name
|
||||||
|
* Make CGO_ENABLED configurable for etcd 3.5
|
||||||
|
* etcdserver: drain leaky goroutines before test completed
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Sep 2 15:08:01 UTC 2024 - Wolfgang Frisch <wolfgang.frisch@suse.com>
|
||||||
|
|
||||||
|
- vendor-update.sh: Fix static /tmp file issue (bsc#1199031)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Mon Mar 25 09:07:45 UTC 2024 - Elisei Roca <eroca@suse.com>
|
Mon Mar 25 09:07:45 UTC 2024 - Elisei Roca <eroca@suse.com>
|
||||||
|
|
||||||
|
97
etcd.conf
97
etcd.conf
@ -1,56 +1,125 @@
|
|||||||
# set commandline options
|
|
||||||
# example: ETCD_OPTIONS="--enable-v2=true" to enable the v2 API
|
# Caution: If you mix-and-match configuration options, then the following rules apply.
|
||||||
#ETCD_OPTIONS=
|
# Command-line flags take precedence over environment variables.
|
||||||
|
# If you provide a configuration file all command-line flags and environment variables are ignored.
|
||||||
|
|
||||||
|
# Set commandline options example: ETCD_OPTIONS="--enable-v2=true" to enable the v2 API
|
||||||
|
#ETCD_OPTIONS=""
|
||||||
|
|
||||||
# [member]
|
# [member]
|
||||||
ETCD_NAME=default
|
# Human-readable name for this member.
|
||||||
|
ETCD_NAME="default"
|
||||||
|
# Path to the data directory.
|
||||||
ETCD_DATA_DIR="/var/lib/etcd/default.etcd"
|
ETCD_DATA_DIR="/var/lib/etcd/default.etcd"
|
||||||
|
# Path to the dedicated wal directory.
|
||||||
#ETCD_WAL_DIR=""
|
#ETCD_WAL_DIR=""
|
||||||
|
# Number of committed transactions to trigger a snapshot to disk.
|
||||||
#ETCD_SNAPSHOT_COUNT="10000"
|
#ETCD_SNAPSHOT_COUNT="10000"
|
||||||
|
# Time (in milliseconds) of a heartbeat interval.
|
||||||
#ETCD_HEARTBEAT_INTERVAL="100"
|
#ETCD_HEARTBEAT_INTERVAL="100"
|
||||||
|
# Time (in milliseconds) for an election to timeout.
|
||||||
#ETCD_ELECTION_TIMEOUT="1000"
|
#ETCD_ELECTION_TIMEOUT="1000"
|
||||||
|
# Raise alarms when backend size exceeds the given quota. 0 means use the
|
||||||
|
# default quota.
|
||||||
|
#ETCD_QUOTA_BACKEND_BYTES="0"
|
||||||
# Before changing this setting allowing etcd to be reachable over the network
|
# Before changing this setting allowing etcd to be reachable over the network
|
||||||
# or if you have untrustworthy local users on the system where etc runs please
|
# or if you have untrustworthy local users on the system where etc runs please
|
||||||
# make sure to enable authentication in the [security] section below. Please
|
# make sure to enable authentication in the [security] section below.
|
||||||
# also read README.security for this package
|
# Please also read README.security for this package.
|
||||||
|
# List of comma separated URLs to listen on for peer traffic.
|
||||||
#ETCD_LISTEN_PEER_URLS="http://localhost:2380"
|
#ETCD_LISTEN_PEER_URLS="http://localhost:2380"
|
||||||
|
# List of comma separated URLs to listen on for client traffic.
|
||||||
ETCD_LISTEN_CLIENT_URLS="http://localhost:2379"
|
ETCD_LISTEN_CLIENT_URLS="http://localhost:2379"
|
||||||
|
# Maximum number of snapshot files to retain (0 is unlimited).
|
||||||
#ETCD_MAX_SNAPSHOTS="5"
|
#ETCD_MAX_SNAPSHOTS="5"
|
||||||
|
# Maximum number of wal files to retain (0 is unlimited).
|
||||||
#ETCD_MAX_WALS="5"
|
#ETCD_MAX_WALS="5"
|
||||||
|
# Comma-separated white list of origins for CORS (cross-origin resource sharing).
|
||||||
#ETCD_CORS=""
|
#ETCD_CORS=""
|
||||||
|
# Enable runtime profiling data via HTTP server
|
||||||
|
#ETCD_ENABLE_PPROF="true"
|
||||||
|
# Force to create a new one member cluster.
|
||||||
|
#ETCD_FORCE_NEW_CLUSTER="false"
|
||||||
|
#ETCD_AUTO_COMPACTION_MODE="periodic"
|
||||||
|
#ETCD_AUTO_COMPACTION_RETENTION="1"
|
||||||
#
|
#
|
||||||
# [cluster]
|
# [cluster]
|
||||||
|
# List of this member's peer URLs to advertise to the rest of the cluster.
|
||||||
|
# The URLs needed to be a comma-separated list.
|
||||||
#ETCD_INITIAL_ADVERTISE_PEER_URLS="http://localhost:2380"
|
#ETCD_INITIAL_ADVERTISE_PEER_URLS="http://localhost:2380"
|
||||||
# if you use different ETCD_NAME (e.g. test), set ETCD_INITIAL_CLUSTER value for this name, i.e. "test=http://..."
|
# List of this member's client URLs to advertise to the public.
|
||||||
#ETCD_INITIAL_CLUSTER="default=http://localhost:2380"
|
# The URLs needed to be a comma-separated list.
|
||||||
#ETCD_INITIAL_CLUSTER_STATE="new"
|
|
||||||
#ETCD_INITIAL_CLUSTER_TOKEN="etcd-cluster"
|
|
||||||
ETCD_ADVERTISE_CLIENT_URLS="http://localhost:2379"
|
ETCD_ADVERTISE_CLIENT_URLS="http://localhost:2379"
|
||||||
|
# Discovery URL used to bootstrap the cluster.
|
||||||
#ETCD_DISCOVERY=""
|
#ETCD_DISCOVERY=""
|
||||||
#ETCD_DISCOVERY_SRV=""
|
# Valid values include 'exit', 'proxy'
|
||||||
#ETCD_DISCOVERY_FALLBACK="proxy"
|
#ETCD_DISCOVERY_FALLBACK="proxy"
|
||||||
|
# HTTP proxy to use for traffic to discovery service.
|
||||||
#ETCD_DISCOVERY_PROXY=""
|
#ETCD_DISCOVERY_PROXY=""
|
||||||
|
# DNS domain used to bootstrap initial cluster.
|
||||||
|
#ETCD_DISCOVERY_SRV=""
|
||||||
|
# Comma separated string of initial cluster configuration for bootstrapping.
|
||||||
|
# Example: "infra0=http://10.0.1.10:2380,infra1=http://10.0.1.11:2380,infra2=http://10.0.1.12:2380"
|
||||||
|
#ETCD_INITIAL_CLUSTER=""
|
||||||
|
# Initial cluster token for the etcd cluster during bootstrap.
|
||||||
|
#ETCD_INITIAL_CLUSTER_TOKEN="etcd-cluster"
|
||||||
|
# Initial cluster state ('new' or 'existing').
|
||||||
|
#ETCD_INITIAL_CLUSTER_STATE="new"
|
||||||
|
# Reject reconfiguration requests that would cause quorum loss.
|
||||||
|
#ETCD_STRICT_RECONFIG_CHECK="false"
|
||||||
|
# Accept etcd V2 client requests
|
||||||
|
#ETCD_ENABLE_V2="true"
|
||||||
#
|
#
|
||||||
# [security]
|
# [security]
|
||||||
|
# Path to the client server TLS cert file.
|
||||||
#ETCD_CERT_FILE=""
|
#ETCD_CERT_FILE=""
|
||||||
|
# Path to the client server TLS key file.
|
||||||
#ETCD_KEY_FILE=""
|
#ETCD_KEY_FILE=""
|
||||||
|
# Enable client cert authentication.
|
||||||
#ETCD_CLIENT_CERT_AUTH="false"
|
#ETCD_CLIENT_CERT_AUTH="false"
|
||||||
|
# Path to the client server TLS trusted CA cert file.
|
||||||
#ETCD_TRUSTED_CA_FILE=""
|
#ETCD_TRUSTED_CA_FILE=""
|
||||||
|
# Client TLS using generated certificates
|
||||||
|
#ETCD_AUTO_TLS="false"
|
||||||
|
# Path to the peer server TLS cert file.
|
||||||
#ETCD_PEER_CERT_FILE=""
|
#ETCD_PEER_CERT_FILE=""
|
||||||
|
# Path to the peer server TLS key file.
|
||||||
#ETCD_PEER_KEY_FILE=""
|
#ETCD_PEER_KEY_FILE=""
|
||||||
|
# Enable peer client cert authentication.
|
||||||
#ETCD_PEER_CLIENT_CERT_AUTH="false"
|
#ETCD_PEER_CLIENT_CERT_AUTH="false"
|
||||||
|
# Path to the peer server TLS trusted CA cert file.
|
||||||
#ETCD_PEER_TRUSTED_CA_FILE=""
|
#ETCD_PEER_TRUSTED_CA_FILE=""
|
||||||
|
# Peer TLS using generated certificates.
|
||||||
|
#ETCD_PEER_AUTO_TLS="false"
|
||||||
|
# Allowed CN for inter peer authentication.
|
||||||
|
#ETCD_PEER_ALLOWED_CN=""
|
||||||
|
# Allowed TLS hostname for inter peer authentication.
|
||||||
|
#ETCD_PEER_ALLOWED_HOSTNAME=""
|
||||||
|
# The validity period of the self-signed certificate, the unit is year.
|
||||||
|
#ETCD_SELF_SIGNED_CERT_VALIDITY="1"
|
||||||
|
# Limit etcd to a specific set of tls cipher suites
|
||||||
|
#ETCD_CIPHER_SUITES=""
|
||||||
|
# Limit etcd to specific TLS protocol versions
|
||||||
|
#ETCD_TLS_MIN_VERSION="TLS1.2"
|
||||||
|
#ETCD_TLS_MAX_VERSION="TLS1.3"
|
||||||
#
|
#
|
||||||
# [logging]
|
# [logging]
|
||||||
|
# Enable debug-level logging for etcd.
|
||||||
#ETCD_LOG_LEVEL="debug"
|
#ETCD_LOG_LEVEL="debug"
|
||||||
# examples for -log-package-levels etcdserver=WARNING,security=DEBUG
|
#ETCD_LOGGER="zap"
|
||||||
#ETCD_LOG_PACKAGE_LEVELS=""
|
# Specify 'stdout' or 'stderr' to skip journald logging even when running under systemd.
|
||||||
|
#ETCD_LOG_OUTPUTS="stderr"
|
||||||
#
|
#
|
||||||
# [proxy] Note: flags will be deprecated in v3.6. "proxy" supports v2 API only.
|
# [proxy] Note: flags will be deprecated in v3.6. "proxy" supports v2 API only.
|
||||||
|
# Valid values include 'on', 'readonly', 'off'
|
||||||
#ETCD_PROXY="off"
|
#ETCD_PROXY="off"
|
||||||
|
# Time (in milliseconds) an endpoint will be held in a failed state.
|
||||||
#ETCD_PROXY_FAILURE_WAIT="5000"
|
#ETCD_PROXY_FAILURE_WAIT="5000"
|
||||||
|
# Time (in milliseconds) of the endpoints refresh interval.
|
||||||
#ETCD_PROXY_REFRESH_INTERVAL="30000"
|
#ETCD_PROXY_REFRESH_INTERVAL="30000"
|
||||||
|
# Time (in milliseconds) for a dial to timeout.
|
||||||
#ETCD_PROXY_DIAL_TIMEOUT="1000"
|
#ETCD_PROXY_DIAL_TIMEOUT="1000"
|
||||||
|
# Time (in milliseconds) for a write to timeout.
|
||||||
#ETCD_PROXY_WRITE_TIMEOUT="5000"
|
#ETCD_PROXY_WRITE_TIMEOUT="5000"
|
||||||
|
# Time (in milliseconds) for a read to timeout.
|
||||||
#ETCD_PROXY_READ_TIMEOUT="0"
|
#ETCD_PROXY_READ_TIMEOUT="0"
|
||||||
|
@ -21,6 +21,7 @@ RestrictRealtime=true
|
|||||||
Type=notify
|
Type=notify
|
||||||
WorkingDirectory=/var/lib/etcd/
|
WorkingDirectory=/var/lib/etcd/
|
||||||
EnvironmentFile=-/etc/sysconfig/etcd
|
EnvironmentFile=-/etc/sysconfig/etcd
|
||||||
|
EnvironmentFile=-/etc/default/etcd
|
||||||
User=etcd
|
User=etcd
|
||||||
# set GOMAXPROCS to number of processors
|
# set GOMAXPROCS to number of processors
|
||||||
ExecStart=/bin/bash -c "GOMAXPROCS=$(nproc) /usr/sbin/etcd $ETCD_OPTIONS"
|
ExecStart=/bin/bash -c "GOMAXPROCS=$(nproc) /usr/sbin/etcd $ETCD_OPTIONS"
|
||||||
|
16
etcd.spec
16
etcd.spec
@ -15,6 +15,7 @@
|
|||||||
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||||
#
|
#
|
||||||
|
|
||||||
|
%global etcd_default_file /etc/default/etcd
|
||||||
|
|
||||||
%define project go.etcd.io/etcd
|
%define project go.etcd.io/etcd
|
||||||
#Compat macro for new _fillupdir macro introduced in Nov 2017
|
#Compat macro for new _fillupdir macro introduced in Nov 2017
|
||||||
@ -22,7 +23,7 @@
|
|||||||
%define _fillupdir %{_localstatedir}/adm/fillup-templates
|
%define _fillupdir %{_localstatedir}/adm/fillup-templates
|
||||||
%endif
|
%endif
|
||||||
Name: etcd
|
Name: etcd
|
||||||
Version: 3.5.12
|
Version: 3.5.18
|
||||||
Release: 0
|
Release: 0
|
||||||
Summary: Highly-available key value store for configuration and service discovery
|
Summary: Highly-available key value store for configuration and service discovery
|
||||||
License: Apache-2.0
|
License: Apache-2.0
|
||||||
@ -32,10 +33,11 @@ Source: %{name}-%{version}.tar.gz
|
|||||||
Source1: vendor.tar.gz
|
Source1: vendor.tar.gz
|
||||||
Source11: %{name}.conf
|
Source11: %{name}.conf
|
||||||
Source12: %{name}.service
|
Source12: %{name}.service
|
||||||
|
Source13: %{name}.sysconfig
|
||||||
Source15: README.security
|
Source15: README.security
|
||||||
Source16: system-user-etcd.conf
|
Source16: system-user-etcd.conf
|
||||||
Source17: vendor-update.sh
|
Source17: vendor-update.sh
|
||||||
BuildRequires: golang(API) >= 1.20
|
BuildRequires: golang(API) >= 1.22
|
||||||
BuildRequires: golang-packaging
|
BuildRequires: golang-packaging
|
||||||
BuildRequires: systemd-rpm-macros
|
BuildRequires: systemd-rpm-macros
|
||||||
BuildRequires: sysuser-tools
|
BuildRequires: sysuser-tools
|
||||||
@ -108,13 +110,19 @@ install -D -p -m 0644 %{SOURCE12} %{buildroot}%{_unitdir}/%{name}.service
|
|||||||
ln -sf %{_sbindir}/service %{buildroot}%{_sbindir}/rc%{name}
|
ln -sf %{_sbindir}/service %{buildroot}%{_sbindir}/rc%{name}
|
||||||
|
|
||||||
# Sysconfig
|
# Sysconfig
|
||||||
install -D -p -m 0644 %{SOURCE11} %{buildroot}%{_fillupdir}/sysconfig.%{name}
|
install -D -p -m 0644 %{SOURCE13} %{buildroot}%{_fillupdir}/sysconfig.%{name}
|
||||||
|
install -D -p -m 0644 %{SOURCE11} %{buildroot}%{etcd_default_file}
|
||||||
|
|
||||||
# Additional
|
# Additional
|
||||||
install -d -m 750 %{buildroot}%{_localstatedir}/lib/%{name}
|
install -d -m 750 %{buildroot}%{_localstatedir}/lib/%{name}
|
||||||
install -Dm0644 %{SOURCE16} %{buildroot}%{_sysusersdir}/system-user-etcd.conf
|
install -Dm0644 %{SOURCE16} %{buildroot}%{_sysusersdir}/system-user-etcd.conf
|
||||||
|
|
||||||
%pre -f %{name}.pre
|
%pre -f %{name}.pre
|
||||||
|
if [ ! -e %{etcd_default_file} -a /etc/sysconfig/etcd ] ; then
|
||||||
|
echo "Migrating existing /etc/sysconfig/etcd to %{etcd_default_file}."
|
||||||
|
echo "From now on only ETCD_OPTIONS should be in /etc/sysconfig/etcd"
|
||||||
|
mv -i /etc/sysconfig/etcd %{etcd_default_file}
|
||||||
|
fi
|
||||||
%service_add_pre %{name}.service
|
%service_add_pre %{name}.service
|
||||||
|
|
||||||
%post
|
%post
|
||||||
@ -140,6 +148,8 @@ install -Dm0644 %{SOURCE16} %{buildroot}%{_sysusersdir}/system-user-etcd.conf
|
|||||||
# Sysconfig
|
# Sysconfig
|
||||||
%{_fillupdir}/sysconfig.%{name}
|
%{_fillupdir}/sysconfig.%{name}
|
||||||
|
|
||||||
|
%config(noreplace) %{etcd_default_file}
|
||||||
|
|
||||||
# Additional
|
# Additional
|
||||||
%dir %attr(0750,%{name},%{name}) %{_localstatedir}/lib/%{name}
|
%dir %attr(0750,%{name},%{name}) %{_localstatedir}/lib/%{name}
|
||||||
|
|
||||||
|
9
etcd.sysconfig
Normal file
9
etcd.sysconfig
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
## Path: Applications/etcd
|
||||||
|
## Description: etcd key value store
|
||||||
|
## Type: string()
|
||||||
|
## Default: ""
|
||||||
|
## ServiceRestart: etcd
|
||||||
|
#
|
||||||
|
# additional options to pass to etcd. e.g. --enable-v2=true
|
||||||
|
#
|
||||||
|
ETCD_OPTIONS=""
|
@ -4,6 +4,7 @@
|
|||||||
# Author: Elisei Roca
|
# Author: Elisei Roca
|
||||||
#------------------------------------
|
#------------------------------------
|
||||||
|
|
||||||
|
set -eo pipefail
|
||||||
# set -x
|
# set -x
|
||||||
|
|
||||||
NAME=etcd
|
NAME=etcd
|
||||||
@ -14,21 +15,26 @@ VERSION=$(grep -oP '(?<=Version:)(.*)' etcd.spec | xargs)
|
|||||||
|
|
||||||
echo "Updating vendor file..."
|
echo "Updating vendor file..."
|
||||||
|
|
||||||
rm -rf /tmp/"$NAME" ||:
|
tempdir="$(mktemp -d --suffix=.etcd)"
|
||||||
mkdir -p /tmp/"$NAME"/vendor
|
function cleanup() {
|
||||||
|
rm -rf "${tempdir}"
|
||||||
|
}
|
||||||
|
trap cleanup EXIT
|
||||||
|
|
||||||
tar --strip-components=1 -xvf "$NAME-$VERSION".tar.gz -C /tmp/"$NAME" &> /dev/null
|
mkdir -p "${tempdir}/vendor"
|
||||||
|
|
||||||
|
tar --strip-components=1 -xvf "$NAME-$VERSION".tar.gz -C "${tempdir}" &> /dev/null
|
||||||
|
|
||||||
dir=$(pwd)
|
dir=$(pwd)
|
||||||
for item in ${STACK[*]}; do
|
for item in ${STACK[*]}; do
|
||||||
mkdir /tmp/"$NAME"/vendor/"$item"
|
mkdir "${tempdir}/vendor/${item}"
|
||||||
cd /tmp/"$NAME/$item"
|
cd "${tempdir}/${item}"
|
||||||
go mod vendor
|
go mod vendor
|
||||||
mv vendor/ ../vendor/"$item"
|
mv vendor/ ../vendor/"$item"
|
||||||
done
|
done
|
||||||
cd "$dir"
|
cd "$dir"
|
||||||
|
|
||||||
fdupes -r -1 /tmp/"$NAME"/vendor/ |
|
fdupes -r -1 "${tempdir}/vendor/" |
|
||||||
while read line; do
|
while read line; do
|
||||||
target="";
|
target="";
|
||||||
for file in ${line[*]}; do
|
for file in ${line[*]}; do
|
||||||
@ -40,7 +46,6 @@ fdupes -r -1 /tmp/"$NAME"/vendor/ |
|
|||||||
done;
|
done;
|
||||||
done
|
done
|
||||||
|
|
||||||
tar -czvf vendor.tar.gz -C /tmp/"$NAME" vendor &> /dev/null
|
tar -czvf vendor.tar.gz -C "${tempdir}" vendor &> /dev/null
|
||||||
rm -rf /tmp/"$NAME" ||:
|
|
||||||
|
|
||||||
echo "Repacked to vendor.tar.gz"
|
echo "Repacked to vendor.tar.gz"
|
||||||
|
@ -1,3 +1,3 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
version https://git-lfs.github.com/spec/v1
|
||||||
oid sha256:b617a120bb3aba3a12f7c06a129ecfbdacbe1456a0470e4cc73e4aeb3a9732be
|
oid sha256:faf835717c582e9640b188e218b75f69203af053a99af66905f053a10bb0c294
|
||||||
size 5406488
|
size 5499588
|
||||||
|
Loading…
x
Reference in New Issue
Block a user