This is a mechanically generated change to replace openstack.org
git:// URLs with https:// equivalents.
This is in aid of a planned future move of the git hosting
infrastructure to a self-hosted instance of gitea (https://gitea.io),
which does not support the git wire protocol at this stage.
This update should result in no functional change.
For more information see the thread at
http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003825.html
Change-Id: I11be0b9c0e53d7730e82d845bc9d3bc2e5ff6420
As time has gone on we've updated module versions in our global module
list making the pinned versions in this module inaccurate. Be more
forgiving so that we can update modules as needed without raising
warnings.
Change-Id: I77f0b9a541710236bcfed3b3c78b94d101152bc1
The puppet-drush module that the puppet-drupal module depends on has
some quirks on puppet 4. First, with the new ordering algorithm, it's
not guaranteed that the drush repo and the composer installation will
happen in the same order as before. We can fix that without touching the
drush module itself by creating resource orderings from the
drupal::drush class. Second, on puppet 3 the empty string '' was
interpreted as falsey, so you could expect `if '' {}` to evaluate as
false. On puppet 4, it's interpreted as truthy, and for the drush module
using '' as the default for the git_tag parameter causes the drush
$git_ref variable to be set to the empty string which causes the module
to stay on the master branch instead of checking out the 6.x branch.
There's no semantic difference between the git_branch and git_tag
parameter, so we'll just set git_tag to the same as git_branch.
Change-Id: I3acbda4edd546b4f145c9991f18ca80bb3e2171e
Since the chain file contents parameter defaults to undef, on puppet 3
the ERB template evaluates that to the symbol :undef which is not
falsey, so if it is left unset it creates an invalid apache config
pointing to /etc/apache2/undef. To be safe, explicitly check for any
emptyish values. This is only an issue for tests on puppet 3, on puppet
4 undef is correctly evaluated as nil.
Change-Id: I380d69f3928e342562c3c63e35a07555163733e8
When serveraliases is not defined it should evaluate to nil, not ''.
Check for both to cover our bases.
Change-Id: Iad51146400443fce963889d77eae3c6e4759d08c
The logic in the Gemfile was relying on Zuulv2 variables to find out
whether the spec helper gem was already available on disk, and since
Zuulv3 has changed things it was failing to find it and downloading the
master version instead. This patch ensures the Gemfile looks for the gem
in the right place when running in CI.
Change-Id: Ifa3b018bf367540dd25d732b2fb5a561df47ce46
Dynamic scoping for variables in ERB templates was removed in puppet
4[1] which means that the variables defined in the
manifest cannot be found when it is referenced in
the httpd::vhost defined type and will be evaluated as nil when
puppet runs. Use scope.lookupvar instead to be explicit about the
variable's source.
[1] https://puppet.com/docs/puppet/4.10/lang_updating_manifests.html#dynamic-scoping-in-erb
Change-Id: Ifc1db7851d2a0cd39af9f05b55ec9a546a12f567
Without this patch, puppet 4 apply tests can't find the drush defined type
and fail with:
Evaluation Error: Resource type not found: Drush at /etc/puppetlabs/code/modules/drupal/manifests/init.pp:241:38
This patch ensures the resource reference is namespaced properly.
Change-Id: Ibd1972c681085344a36c51951f32aa3e93e501c8
Puppet 4 is more strict about data types and doesn't tolerate using
arithmetic operators on strings. The operatingsystemrelease fact is a
string. Switch the arithmetic comparison to a native function that knows
how to deal with version numbers.
Change-Id: I4dd58b28ad5b4bd64ba0b6eed6e2b8c312bdb5fa
Instead of keeping a local copy of spec_helper_acceptance.rb and
requiring updates to all modules for any change, we can move it into the
common helper gem and require it from there. This will make it easier to
create and review changes that affect all puppet modules. Also change
the Gemfile to look for the gem in the local workspace if running in a
zuul environment.
Change-Id: Iac4b8137c8a8621083ced76879e9f4fbe1ce70a0
Add a xenial nodeset and update the spec helper to install puppet 3 from
the Ubuntu repos instead of from puppetlabs.
Change-Id: I0a23589cc782e5689087aea53dbe364e9faa83ad
Bindep is a tool for checking the presence of binary packages needed
to use an application / library. It started life as a way to make it
easier to set up a development environment for OpenStack projects.
Change-Id: I81dc96c1338e912969ae7a99eaaa1886eb6d6412
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
Apache version 2.4 changes the Order Allow,Deny security configuration options.
This patch modifies the vhost template in order to support it and provide
trusty compatibility.
Change-Id: I1514ab788f8bfd9198ae020ea1fab745cee6f305
As the Pear Drush deployment model is deprecated now, the Drupal puppet
will use the standard puppet-drupal module for drush cli installation.
Change-Id: I9d6afacc3ca9241bf1419102be01d44409ded8da
Depends-On: I71e4356d0b6861dd648d069d5e31f002b3b0cc83
Order and intendation of those parameters are changed
to follow Puppet Style Guide recommendation [0].
Moreover, it will allow to an user to find much faster
a variable in a list of variables.
[0]. https://docs.puppetlabs.com/guides/style_guide.html
Change-Id: I9cda8c74a7b69c7fd96d103b913ed51e95aa2ea8
This patch removes the explicit installation of the mysql-client package because:
- when using the older mysql module it is unnecessary, as the
mysql::db type requires the mysql::server class, which installs the
mysql-server package, which installs the mysql-client package as a
side effect. This is only true for Ubuntu, but as this module only
works on Ubuntu currently we do not need to be concerned with how
other operating systems behave.
- when using a modern mysql module, the mysql::db type includes the
mysql::client class, which installs the mysql-client package
explicitly. This conflicts with the explicit installation in the
drupal module.
This patch will allow the drupal module to work with an up-to-date
version of the mysql module while not causing any negative effects
while the older version is still installed.
Change-Id: Ia472dafdf60b9f1b813d4fc9a6c42f9259f1e203
If $site_base_url and $conf are unset, catalog compilation fails
because the cron resource tries to access $conf['cron_key'] and $conf
is not a hash. If $conf is a hash but does not contain the 'cron_key'
key, a cron is created with the command
wget -O /dev/null -q -t 1 false/cron.php?cron_key=
which is not sensible and will result in failed crons. It only makes
sense to create this cron if $site_base_url and $conf are set, so this
patch checks that they are set before creating the cron resource.
Change-Id: Ib40350e7b3c5c6261812d00a20decd8692acb4bb
If the user wants to create a drupal database, the username, password,
and database name must be set. This patch sets reasonable defaults for
$mysql_user and $mysql_database, and causes the catalog to fail if the
user does not provide $mysql_password, but only if
$site_create_database is set.
Change-Id: I829ebb1543d4733875dba3da5e900ae1ad6d64dc
The $site_root parameter must be set in order for the file resource
ensuring it to work. However, the best default for it depends on the
$site_name and $site_vhosts_root parameter. Class parameter defaults
behave strangely if they depend on another class parameter: they take
on the value of whatever the user has set, not the default value. So if
we want the default value of $site_root to be
"${site_vhosts_root}/${site_name}", and we want it to be acceptable to
use the default value of 'www.example.com' as the site name, then we
have to set the default in the body of the class, not in the parameters
list. The same is true for the $site_docroot parameter.
This patch leaves the official default of $site_root as undef but
conditionally sets a preferred default of "${site_vhosts_root}/${site_name}" in
the body of the class. Since variables in puppet are immutable we need
to assign this value to a new variable and fix the references to this
variable throughout hte module.
This patch changes the official default of $site_docroot from
"${site_root}/w" to undef, because that default would have different
behavior depending on whether the user had set $site_root or not. We
then conditionally set it to the right default in the body of the class
and update references to that variable. Also changed the Directory key
for the docroot in the vhost template to refer to the $docroot
parameter passed in to the httpd::vhost type rather than the
$_site_docroot value from the class, which evaluates to the same value
but makes the Directory tag consistent with the Docroot declaration
above it.
Change-Id: Iaed65b20816c0b4f6fd34f7e0ef07f906bb9750e
The default values for the $ssl_*_contents parameters is undef, so
checking whether they match empty string is not sensible. Fix the
conditionals to check for the case when the user has left the value
unset.
It is reasonable to conditionally not create these certificate files
even when $site_ssl_enabled is set because the path variables may be
set to a snakeoil cert.
Change-Id: I274dbe80a0547336601c12c4e876ba9591798996
If left undefined, the drupal class will create a vhost file named
50-.conf with an empty ServerName, and httpd will fail to start. Use
$::fqdn as a default site_name instead.
This will not affect Infra as Infra specifies this value explicitly.
Any downstream users must also be specifying this value explicitly for
the module to work, so this is a safe change.
Change-Id: Ia639f05a4ba7072812a1c4d6bb3a702fce493d02
The distbuild defined type doesn't exist since 9adc5fd7, so notifying
it results in a catalog compilation error.
Change-Id: I9ced1f198be5e653ee7da1837a2b93e5aad815e7
Use same target directory for zuul-cloner and
the regular git command.
Change-Id: I1966b2a107188d32fb0ce1571dc8f8579f921867
Co-Authored-By: Fabien Boucher <fabien.boucher@enovance.com>
In anticipation of puppet 4, start trying to deal with puppet 4 things
that can be helpfully predicted by puppet lint plugins. This patch also
corrects lint errors caught by the puppet-lint-absolute_classname-check
and puppet-lint-empty_string-check gems as well as arrow alignment
which wasn't being caught under the system version of puppet-lint.
Change-Id: I91cb2fdeb458edbd41e777be74d292a564bf2d58
puppet-httpd is the openstack-infra version of puppetlabs-apache
(0.0.4) release.
This patchset will remove the puppetlabs-apache namespace from -infra
allowing for possible future patchsets to use newer puppetlabs-apache
modules.
Change-Id: I341295e1969b9ff1d54ac84655c1eb340b239684
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
The http://ci.openstack.org/ documentation site has been deprecated,
replaced by redirects to corresponding paths within
http://docs.openstack.org/infra/ where other Project Infrastructure
documentation already resides.
Change-Id: I52ca8fefdfc9bc105b1e5045f93183119235757b
The conf_xxxx class paramters of drupal class refactored now
to conf variable that can hold the key-value pairs. So it
will allow the define additional parameters without any change
required in the drupal:: class.
The conf_xxx parameters kept only for compatibility reason, will be
removed in a future release.
Change-Id: I9e77d609bc6aaa3a5e10f065e79aa8a86cae151e
The content of this project is Apache 2 licensed, but we should
include a standard LICENSE file just to be clear about that.
Change-Id: Iee6320b9d7e35fbe8d3b0a9794f3e485c18ef2c8
We were testing if the chain file contents var was not equal to empty
string ('') before setting the chain file path in the vhost.
Unfortunately this variable was unset so has a value of nil in the erb
file. This meant that the condition matched even though we didn't want
it to and we got a broken vhost file.
Fix this by explicitly setting this var's value to undef by default in
puppet. This results in a nil value erb side which we can test against
more simply.
Change-Id: I8016b7ab20843a6e35002bed1a79867480ddbd08
Extend the Drupal vhost template with ssl capability, and
groups-dev.openstack.org now accepts the following hiera variables for
ssl setup:
- groups_dev_site_ssl_cert_file_contents: x509 certificate of vhost in pem format
- groups_dev_site_ssl_key_file_contents: rsa key of x509 certificate in pem format
- groups_dev_site_ssl_chain_file_contents: trusted chain of parent certificates (optional)
This patch is required for proper openstackid/oauth2 backref communication.
Change-Id: Ia148d1db743fc80bcb675c9ca2906333ef62eff8
Implements: blueprint groups-oauth2-authentication
Move the openid provider url into groups_openid_provider configuration
variable for groups portal. We are separating the productive and
staging urls, so productive is pointing to openstackid.org now.
Change-Id: Ifc7d5d41b80c3a080800d1d9d1ef394490d93b14
The v0.10 version contains an important file permission fix.
Upgrading the site into slot1 not properly set the file permissions
of the symlinked vhost directory and apache failed to serve the
entire site. This issue affected every 2nd deployments and resulted
in a WSOD.
Change-Id: Iaab38356b98e09a0738547e7984bffe9b428398d
Both staging and productive groups instances will use the manifest
published at tarballs.openstack.org/groups/drupal-updates catalog.
It helps to separate the staging and prod deployment source
versions, passed in package_branch parameter. Drush dsd tool updated
to v0.9, and puppet sitedeploy and siteupdate resources were also
refactored to support drush-dl package provider parameters.
Change-Id: I8299c063ea774a85554c2406c6cb6ccb007fb182
Add optional GA tracking code variable to settings.php template and add
tracking code to groups.openstack.org site.
Change-Id: Iddf223cab9ef672178f4e2984cdacf27a8d0f16f
* modules/drupal/manifests/init.pp: Since the cron URL can return
content, write it to the bitbucket so that we don't annoy sysadmins
with cronspam every five minutes.
Change-Id: I9df9510eb14e89c380dadba98cd4834a6a83fffc
Groups-dev portal failed to download the release updates from
tarball.openstack.org/groups site, meanwhile the drush dsd-status tool
reported an update available status. This patch resolves this issue
and site-deploy and site-update executed when the .md5 file downloaded
from tarball site updated. The wget --timestamping options is used
to download the .md5 file in case of remote update only.
Change-Id: Iab237567e45864835274c01c8e93363c7ea8b620
Closes-Bug: #1334707
Update the upstream version of drush dsd tool used to update
Drupal siteroot to v0.8 that fixes settings.php ownership
problem during a drush dsd-update process.
Change-Id: I3c88320905e9a65a9335d7cd78ab46bf8649e5ad
Closes-Bug: #1334625