From ead7f3c706657bbfae37ff40c8f919fb57c8a841 Mon Sep 17 00:00:00 2001 From: Nick Walker Date: Thu, 31 Jan 2019 16:58:13 -0800 Subject: [PATCH 1/4] Rename site directory to site-modules Prior to this commit, we placed modules local to a users installation in the `site` directory. This was just a convention and the name `site` doesn't clearly convey what it is for. After this commit, we place modules local to a users installation in the `site-modules` directory. This makes it more clear to users that this is a directory that modules go i. When users start with bolt they won't even know what a control-repo is and renaming site to site-modules gives them a better idea of why they should put their modules with tasks in them. Also see: https://tickets.puppetlabs.com/browse/BOLT-1108 --- environment.conf | 2 +- {site => site-modules}/profile/manifests/base.pp | 0 {site => site-modules}/profile/manifests/example.pp | 0 {site => site-modules}/role/manifests/database_server.pp | 0 {site => site-modules}/role/manifests/example.pp | 0 {site => site-modules}/role/manifests/webserver.pp | 0 6 files changed, 1 insertion(+), 1 deletion(-) rename {site => site-modules}/profile/manifests/base.pp (100%) rename {site => site-modules}/profile/manifests/example.pp (100%) rename {site => site-modules}/role/manifests/database_server.pp (100%) rename {site => site-modules}/role/manifests/example.pp (100%) rename {site => site-modules}/role/manifests/webserver.pp (100%) diff --git a/environment.conf b/environment.conf index a986777..11e1003 100644 --- a/environment.conf +++ b/environment.conf @@ -1,2 +1,2 @@ -modulepath = site:modules:$basemodulepath +modulepath = site-modules:modules:$basemodulepath config_version = 'scripts/config_version.sh $environmentpath $environment' diff --git a/site/profile/manifests/base.pp b/site-modules/profile/manifests/base.pp similarity index 100% rename from site/profile/manifests/base.pp rename to site-modules/profile/manifests/base.pp diff --git a/site/profile/manifests/example.pp b/site-modules/profile/manifests/example.pp similarity index 100% rename from site/profile/manifests/example.pp rename to site-modules/profile/manifests/example.pp diff --git a/site/role/manifests/database_server.pp b/site-modules/role/manifests/database_server.pp similarity index 100% rename from site/role/manifests/database_server.pp rename to site-modules/role/manifests/database_server.pp diff --git a/site/role/manifests/example.pp b/site-modules/role/manifests/example.pp similarity index 100% rename from site/role/manifests/example.pp rename to site-modules/role/manifests/example.pp diff --git a/site/role/manifests/webserver.pp b/site-modules/role/manifests/webserver.pp similarity index 100% rename from site/role/manifests/webserver.pp rename to site-modules/role/manifests/webserver.pp From 80494c198b07557713ae3d44811935fcd9b215da Mon Sep 17 00:00:00 2001 From: Nick Walker Date: Mon, 4 Feb 2019 13:04:11 -0800 Subject: [PATCH 2/4] Add symlink from site to site-modules for compatibility --- site | 1 + 1 file changed, 1 insertion(+) create mode 120000 site diff --git a/site b/site new file mode 120000 index 0000000..5c6f04b --- /dev/null +++ b/site @@ -0,0 +1 @@ +site-modules/ \ No newline at end of file From baa4b92a8801df4ad026da13b0e0bd68c5cbdd3a Mon Sep 17 00:00:00 2001 From: Reid Vandewiele Date: Mon, 25 Feb 2019 09:08:36 -0800 Subject: [PATCH 3/4] Remove symlink site -> site-modules The symlink served for a good discussion point around change impact, but in the end having it makes for a more confusing experience overall both to new users cloning the control-repo to get started and also to anyone accustomed to "site". A new user won't miss "site". A symlink will muddy the waters over the change for long-time users. Better for clarity to be all-in and not include a symlink. --- site | 1 - 1 file changed, 1 deletion(-) delete mode 120000 site diff --git a/site b/site deleted file mode 120000 index 5c6f04b..0000000 --- a/site +++ /dev/null @@ -1 +0,0 @@ -site-modules/ \ No newline at end of file From c74c84d243b8c754f4e4b0342d334c63eb64227d Mon Sep 17 00:00:00 2001 From: Reid Vandewiele Date: Mon, 25 Feb 2019 09:13:35 -0800 Subject: [PATCH 4/4] Update README to reflect site -> site-modules --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index ac57c92..808091f 100644 --- a/README.md +++ b/README.md @@ -19,9 +19,9 @@ The important files and items in this template are as follows: * An example Hiera configuration file and data directory with pre-created common.yaml and nodes directory. * These match the default hierarchy that ships with PE. * An [environment.conf](https://puppet.com/docs/puppet/5.3/config_file_environment.html) that correctly implements: - * A site directory for roles, profiles, and any custom modules for your organization. - * A config_version script. -* An example [config_version](https://puppet.com/docs/puppet/5.3/config_file_environment.html#configversion) script that outputs the git commit ID of the code that was used during a Puppet run. + * A site-modules directory for roles, profiles, and any custom modules for your organization. + * A config\_version script. +* An example [config\_version](https://puppet.com/docs/puppet/5.3/config_file_environment.html#configversion) script that outputs the git commit ID of the code that was used during a Puppet run. Here's a visual representation of the structure of this repository: @@ -36,7 +36,7 @@ control-repo/ │   ├── code_manager_config_version.rb # A config_version script for Code Manager. │   ├── config_version.rb # A config_version script for r10k. │   └── config_version.sh # A wrapper that chooses the appropriate config_version script. -├── site/ # This directory contains site-specific modules and is added to $modulepath. +├── site-modules/ # This directory contains site-specific modules and is added to $modulepath. │   ├── profile/ # The profile module. │   └── role/ # The role module. ├── LICENSE