Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-objvar
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Jobs
Commits
Open sidebar
uplex-varnish
varnish-objvar
Commits
826577d4
Commit
826577d4
authored
Apr 26, 2021
by
Geoff Simmons
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Set version 0.2.0, and add RPM packaging.
parent
2b58f9bb
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
150 additions
and
1 deletion
+150
-1
configure.ac
configure.ac
+1
-1
pkg
pkg/rpm/pkg
+62
-0
varnish-objvar.spec
pkg/rpm/varnish-objvar.spec
+66
-0
varnishcache_varnish66.repo
pkg/rpm/varnishcache_varnish66.repo
+21
-0
No files found.
configure.ac
View file @
826577d4
AC_PREREQ([2.68])
AC_INIT([varnish-objvar], [0.
1
])
AC_INIT([varnish-objvar], [0.
2.0
])
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_AUX_DIR([build-aux])
AC_CONFIG_HEADER([config.h])
...
...
pkg/rpm/pkg
0 → 100755
View file @
826577d4
#! /bin/bash -ex
# Build script for a varnish-objvar el7 RPM
# to be run in the rpmbuild/centos7 docker container.
# Env variables VERSION and RELEASE MUST be set in the docker invocation.
# DIST is set by the rpmbuild/centos7 container.
# The directory mounted to /srv MUST contain these files:
# - this script (named pkg)
# - varnish-objvar tarball (varnish-objvar-$VERSION.tar.gz)
# - RPM spec file (varnish-objvar.spec)
# - yum repo config for varnish66@packagecloud (varnishcache_varnish66.repo)
# (see https://packagecloud.io/varnishcache/varnish66/install#manual-rpm)
# So this is a sample docker invocation:
#
# $ docker run -t -v $PWD:/srv -e VERSION=1.2.3 -e RELEASE=4711 \
# rpmbuild/centos7 /srv/pkg
# At the end of the run, binary, source and debuginfo RPMs are in the
# directory mounted to /srv.
if
[
-z
$VERSION
]
;
then
echo
"Env variable VERSION MUST be set"
exit
1
fi
if
[
-z
$RELEASE
]
;
then
echo
"Env variable RELEASE MUST be set"
exit
1
fi
# delete the peculiar macros from the rpmbuild/centos7 image
rm
/home/builder/.rpmmacros
# set up the build environment
cd
/home/builder
mkdir
-p
rpmbuild/
{
BUILD,BUILDROOT,RPMS,SOURCES,SPECS,SRPMS
}
cp
/srv/varnish-objvar.spec rpmbuild/SPECS
cp
/srv/varnish-objvar-
${
VERSION
}
.tar.gz rpmbuild/SOURCES
# install epel7 repo
sudo
yum
install
-y
-q
\
https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
# set up varnish repo
sudo cp
/srv/varnishcache_varnish66.repo /etc/yum.repos.d/
sudo
yum
-q
makecache
-y
--disablerepo
=
'*'
--enablerepo
=
'varnishcache_varnish66'
# build requirements
sudo
yum
install
-y
-q
varnish-devel pkgconfig make gcc python-docutils
# build RPMs
rpmbuild
-ba
-D
"dist .
${
DIST
}
"
\
-D
"_version
${
VERSION
}
"
\
-D
"_release
${
RELEASE
}
"
\
rpmbuild/SPECS/varnish-objvar.spec
sudo cp
rpmbuild/RPMS/
*
/
*
/srv
sudo cp
rpmbuild/SRPMS/
*
/srv
pkg/rpm/varnish-objvar.spec
0 → 100644
View file @
826577d4
# -D MUST pass in _version and _release, and SHOULD pass in dist.
Summary: Varnish Modules (VMODs) implementing variable interfaces for VCL
Name: varnish-objvar
Version: %{_version}
Release: %{_release}%{?dist}
License: BSD
Group: System Environment/Daemons
URL: https://code.uplex.de/uplex-varnish/varnish-objvar
Source0: %{name}-%{version}.tar.gz
# varnish from varnish66 at packagecloud
Requires: varnish = 6.6.0
BuildRequires: varnish-devel = 6.6.0
BuildRequires: pkgconfig
BuildRequires: make
BuildRequires: gcc
BuildRequires: gcc-c++
BuildRequires: python-docutils >= 0.6
Provides: varnish-objvar, varnish-objvar-debuginfo
%description
This bundle contains four varnish modules (VMODs) implementing a next
level variable interface using the VCL object model:
%prep
%setup -q -n %{name}-%{version}
%build
%configure
make -j
%check
make -j check
%install
make install DESTDIR=%{buildroot}
# Only use the version-specific docdir created by %doc below
rm -rf %{buildroot}%{_docdir}
# None of these for fedora/epel
find %{buildroot}/%{_libdir}/ -name '*.la' -exec rm -f {} ';'
find %{buildroot}/%{_libdir}/ -name '*.a' -exec rm -f {} ';'
%clean
rm -rf %{buildroot}
%files
%defattr(-,root,root,-)
%{_libdir}/varnish*/vmods/
%{_mandir}/man3/*.3*
%doc README.rst LICENSE INSTALL.rst
%post
/sbin/ldconfig
%changelog
* Mon Apr 26 2021 Geoff Simmons <geoff@uplex.de> - %{_version}-%{_release}
- Compatible with Varnish 6.6
pkg/rpm/varnishcache_varnish66.repo
0 → 100644
View file @
826577d4
[varnishcache_varnish66]
name=varnishcache_varnish66
baseurl=https://packagecloud.io/varnishcache/varnish66/el/7/$basearch
repo_gpgcheck=1
gpgcheck=0
enabled=1
gpgkey=https://packagecloud.io/varnishcache/varnish66/gpgkey
sslverify=1
sslcacert=/etc/pki/tls/certs/ca-bundle.crt
metadata_expire=300
[varnishcache_varnish66-source]
name=varnishcache_varnish66-source
baseurl=https://packagecloud.io/varnishcache/varnish66/el/7/SRPMS
repo_gpgcheck=1
gpgcheck=0
enabled=1
gpgkey=https://packagecloud.io/varnishcache/varnish66/gpgkey
sslverify=1
sslcacert=/etc/pki/tls/certs/ca-bundle.crt
metadata_expire=300
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment