dev-release/v2-craft3
dev-release/v2-craft3 https://craftcms.com/Craft CMS Project
MIT
The Requires
cms project craftcms craft
v1.x-dev
1.9999999.9999999.9999999-dev https://craftcms.com/Craft CMS Project
proprietary
The Requires
Craft CMS Project
A lot has changed since this repo was created. Setting this to read-only as a reference but you'll likely be much better served by a more modern workflow these days., (*2)
Craft Master is a starter project for Craft CMS., (*3)
To create a new project:, (*4)
composer create-project barrelstrength/craft-master <path>
Follow the Craft CMS docs Installation Instructions as appropriate., (*5)
To get setup with a Craft CMS project using Craft Master:, (*6)
.env.example
=> .env
and add your ENVIRONMENT
and database connection infoconfig/local/general.example.php
=> config/local/general.php
and update as desiredCraft provides a framework for configuring a project across multiple environments using environment variables (at the infrastructure level) and multi-environment configs (within the application). Craft Master is designed to work out of the box with the recommended Craft configuration and add flexibility to support a broader range of application configurations., (*7)
Craft Master updates the default Craft starter project in the following ways:, (*8)
vendor
folderstorage
folder (excluding storage/rebrand
)local
, dev
, production
.env
to use local
as the default ENVIRONMENT
variableweb/index.php
to include .multienv.php
and dynamically set the ENVIRONMENT
and SITE_URL
variables.env
settings in config/db.php
to use multi-environment config and fallback to default settings if being used with application level configurationconfig/general.php
to:
env
, baseCpUrl
, siteUrl
, and @web
alias dynamicallydefaultSearchTermOptions
to allow fuzzy searchestokenParam
to use t
securityKey
to support both .env
or fallback to a value defined in config/general.php
userSessionDuration
, rememberedUserSessionDuration
, and rememberUsernameDuration
to one month config/general.php
to support a local override file config/local/general.php
that can be excluded from the repoconfig/local/general.php
with extended login times and several development considerationstemplates/503.twig
CraftTwigAutoCompleteExtension.php
Craft Master prefers to keep all project files in the repository and includes the vendor
folder to track and deploy changes., (*9)
Craft Master updates web/index.php
to include config/multienv.php
which adds support for defining the ENVIRONMENT
and SITE_URL
variables as part of the web request. The ENVIRONMENT
and SITE_URL
variables are used in the config/general.php
file to help define several other settings., (*10)
The Site URL setting is used in several places and can be defined in the .env
file on a per-environment basis., (*11)
Alternatively, Craft Master will dynamically set the SITE_URL
variable if no Site URL is defined in the .env
file. This is done using the $_SERVER['HTTP_HOST']
variable. If you choose this method, be sure your application is using an environment where $_SERVER['HTTP_HOST']
can be trusted. If you are unsure, play it safe and define your Site URL using .env
., (*12)
Alongside these conventions, Craft Master sets the @web
alias dynamically, to help avoid an undesired side effects (such as cache poisoning) if @web
is used with its default behavior., (*13)
The default config/db.php
has been updated to work in concert with .env
so it's easier to use the recommended Craft .env
alongside alternative workflows without the need to define some variables multiple times., (*14)
For local development, define your database credentials in the .env
. In other environments, you can choose to use .env
or a multi-environment application configuration., (*15)
Craft CMS Project
MIT
cms project craftcms craft
Craft CMS Project
proprietary