Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
libvmod-example
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
libvmod-example
Commits
a2caf1e9
Commit
a2caf1e9
authored
Nov 06, 2020
by
Guillaume Quintard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add circleci integration
parent
47b6775e
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
58 additions
and
0 deletions
+58
-0
config.yml
.circleci/config.yml
+55
-0
README.rst
README.rst
+2
-0
rename-vmod-script
rename-vmod-script
+1
-0
No files found.
.circleci/config.yml
0 → 100644
View file @
a2caf1e9
version
:
2.1
# use circleci's pipeline argument to ease configuration.
# this allows you to track the right packages, and to add extra dependencies if needed
# just change the default here
parameters
:
pc-repo
:
description
:
the packagecloud repository to find the Varnish Cache packages. It should match the version you are building against
type
:
string
default
:
"
varnish-weekly"
dep-pkgs
:
description
:
which packages to install to build your vmod(s)
type
:
string
default
:
"
make
automake
libtool
python-sphinx"
# for now, we just build for centos:7, be we can do it for more platforms if needed
jobs
:
build
:
docker
:
-
image
:
centos:7
working_directory
:
/workspace
steps
:
-
run
:
name
:
Install dependencies
command
:
|
curl -s https://packagecloud.io/install/repositories/varnishcache/<< pipeline.parameters.pc-repo >>/script.rpm.sh | bash
yum install -y epel-release
yum install -y git varnish-devel << pipeline.parameters.dep-pkgs >>
-
checkout
-
run
:
name
:
Build and test
command
:
|
./autogen.sh
./configure
make
make check -j 4
make install
# two workflows, identical but for their triggers ()commit/scheduled
workflows
:
version
:
2
# run the build job for all commits
commit
:
&jobs
jobs
:
-
build
# every week, run build too, in case packages got updated
nightly
:
<<
:
*jobs
triggers
:
-
schedule
:
cron
:
"
0
4
*
*
*"
filters
:
branches
:
only
:
-
master
README.rst
View file @
a2caf1e9
...
...
@@ -125,3 +125,5 @@ The basic steps to start a new vmod from this example are::
./rename-vmod-script $name
and follow the instructions output by rename-vmod-script
[![CircleCI](https://circleci.com/gh/varnishcache/libvmod-example/tree/master.svg?style=svg)](https://app.circleci.com/pipelines/github/varnishcache/libvmod-example?branch=master)
rename-vmod-script
View file @
a2caf1e9
...
...
@@ -34,6 +34,7 @@ git mv src/vmod_example.vcc src/vmod_${SYM_NAME}.vcc
git
grep
-z
-l
example | xargs
-0
sed
-i
-s
-e
"s/example/
${
SYM_NAME
}
/g"
git
grep
-z
-l
Example | xargs
-0
sed
-i
-s
-e
"s/Example/
${
CAP_NAME
}
/g"
git
grep
-z
-l
EXAMPLE | xargs
-0
sed
-i
-s
-e
"s/EXAMPLE/
${
UPP_NAME
}
/g"
sed
-i
'/\[\!\[CircleCI\]/d'
README.rst
git
rm
-f
rename-vmod-script
...
...
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