Download CDN purger to cache
This commit is contained in:
parent
196c1403e6
commit
395e67c918
|
@ -3,6 +3,7 @@ class cdn::cache(
|
||||||
Hash[String, Integer] $customers = {
|
Hash[String, Integer] $customers = {
|
||||||
customer1 => 1000000000,
|
customer1 => 1000000000,
|
||||||
}
|
}
|
||||||
|
String $sunet_cdnp_version = '0.0.1'
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
include sunet::packages::certbot
|
include sunet::packages::certbot
|
||||||
|
@ -126,6 +127,12 @@ class cdn::cache(
|
||||||
rule => 'add rule inet filter input meta iifname ip6tnl0 ip6 daddr 2001:6b0:2100::/48 tcp dport { 80, 443 } counter accept comment "sunet-cdn-service6"'
|
rule => 'add rule inet filter input meta iifname ip6tnl0 ip6 daddr 2001:6b0:2100::/48 tcp dport { 80, 443 } counter accept comment "sunet-cdn-service6"'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Download CDN purger
|
||||||
|
exec { "curl -LO https://github.com/SUNET/sunet-cdnp/releases/download/v${sunet_cdnp_version}/sunet-cdnp_${sunet_cdnp_version}_linux_${facts[os][architecture]}.tar.gz":
|
||||||
|
creates => "/root/sunet-cdnp_${sunet_cdnp_version}_linux_${facts[os][architecture]}.tar.gz",
|
||||||
|
cwd => '/root'
|
||||||
|
}
|
||||||
|
|
||||||
if $cache_secrets {
|
if $cache_secrets {
|
||||||
$customers.each |String $customer, Integer $customer_uid| {
|
$customers.each |String $customer, Integer $customer_uid| {
|
||||||
if $cache_secrets['customers'][$customer] {
|
if $cache_secrets['customers'][$customer] {
|
||||||
|
|
Loading…
Reference in a new issue