The nginx::resource::vhost resource creates a nginx::resource::location by
default. This location will be named after the vhost you created (gitlab)
with location "/". You're also declaring your own nginx::resource::location
with vhost name "gitlab" and location "/".
In the nginx module it creates a fragment. The name of this fragment is the
MD5 sum of ${vhost_sanitized}-${priority}-${location_sanitized}. The
default location for your vhost is clashing with the one you are manually
declaring since the MD5 sum of the two fragments are identical due to the
way they are created.
Simplest fix is to set use_default_location => false on the vhost.
On Sunday, 19 April 2015 05:41:04 UTC-4, Danny Roberts wrote:
>
> I am trying to use the jfryman-nginx module (Code is here:
> https://github.com/kemra102/puppet-gitlab/blob/master/manifests/webserver.pp
> )
>
> However when running the module this code is part of it spits out these
> errors:
>
> Error: Duplicate declaration:
> Concat::Fragment[0024e4ac0b2015c6fe48cb277f2f1f98] is already declared in
> file /root/modules/nginx/manifests/resource/location.pp:359; cannot
> redeclare at /root/modules/nginx/manifests/resource/location.pp:359 on node
> gitlab.thefallenphoenix.net
> Error: Duplicate declaration:
> Concat::Fragment[0024e4ac0b2015c6fe48cb277f2f1f98] is already declared in
> file /root/modules/nginx/manifests/resource/location.pp:359; cannot
> redeclare at /root/modules/nginx/manifests/resource/location.pp:359 on node
> gitlab.thefallenphoenix.net
>
> Now unfortunately I cannot unravel the complexities of the nginx module so
> cannot determine exactly what is duplicated that shouldn't be. Can anyone
> provide any insight?
>
--
You received this message because you are subscribed to the Google Groups
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/puppet-users/05f9af86-0006-4a1d-9aff-ff8df8753b63%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.