Skip to content

Commit d9ac67f

Browse files
committed
Bootstrap
1 parent 4da12d9 commit d9ac67f

22 files changed

+7892
-0
lines changed

Diff for: .ddev/config.yaml

+256
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,256 @@
1+
name: automation-workshop
2+
type: php
3+
docroot: web
4+
php_version: "8.0"
5+
webserver_type: nginx-fpm
6+
router_http_port: "80"
7+
router_https_port: "443"
8+
xdebug_enabled: false
9+
additional_hostnames: []
10+
additional_fqdns: []
11+
database:
12+
type: mariadb
13+
version: "10.4"
14+
nfs_mount_enabled: false
15+
mutagen_enabled: false
16+
use_dns_when_possible: true
17+
composer_version: "2"
18+
web_environment: []
19+
nodejs_version: "16"
20+
21+
# Key features of ddev's config.yaml:
22+
23+
# name: <projectname> # Name of the project, automatically provides
24+
# http://projectname.ddev.site and https://projectname.ddev.site
25+
26+
# type: <projecttype> # drupal6/7/8, backdrop, typo3, wordpress, php
27+
28+
# docroot: <relative_path> # Relative path to the directory containing index.php.
29+
30+
# php_version: "7.4" # PHP version to use, "5.6", "7.0", "7.1", "7.2", "7.3", "7.4", "8.0", "8.1"
31+
32+
# You can explicitly specify the webimage but this
33+
# is not recommended, as the images are often closely tied to ddev's' behavior,
34+
# so this can break upgrades.
35+
36+
# webimage: <docker_image> # nginx/php docker image.
37+
38+
# database:
39+
# type: <dbtype> # mysql, mariadb
40+
# version: <version> # database version, like "10.3" or "8.0"
41+
# Note that mariadb_version or mysql_version from v1.18 and earlier
42+
# will automatically be converted to this notation with just a "ddev config --auto"
43+
44+
# router_http_port: <port> # Port to be used for http (defaults to port 80)
45+
# router_https_port: <port> # Port for https (defaults to 443)
46+
47+
# xdebug_enabled: false # Set to true to enable xdebug and "ddev start" or "ddev restart"
48+
# Note that for most people the commands
49+
# "ddev xdebug" to enable xdebug and "ddev xdebug off" to disable it work better,
50+
# as leaving xdebug enabled all the time is a big performance hit.
51+
52+
# xhprof_enabled: false # Set to true to enable xhprof and "ddev start" or "ddev restart"
53+
# Note that for most people the commands
54+
# "ddev xhprof" to enable xhprof and "ddev xhprof off" to disable it work better,
55+
# as leaving xhprof enabled all the time is a big performance hit.
56+
57+
# webserver_type: nginx-fpm # or apache-fpm
58+
59+
# timezone: Europe/Berlin
60+
# This is the timezone used in the containers and by PHP;
61+
# it can be set to any valid timezone,
62+
# see https://en.wikipedia.org/wiki/List_of_tz_database_time_zones
63+
# For example Europe/Dublin or MST7MDT
64+
65+
# composer_root: <relative_path>
66+
# Relative path to the composer root directory from the project root. This is
67+
# the directory which contains the composer.json and where all Composer related
68+
# commands are executed.
69+
70+
# composer_version: "2"
71+
# You can set it to "" or "2" (default) for Composer v2 or "1" for Composer v1
72+
# to use the latest major version available at the time your container is built.
73+
# It is also possible to select a minor version for example "2.2" which will
74+
# install the latest release of that branch. Alternatively, an explicit Composer
75+
# version may be specified, for example "1.0.22". Finally, it is also possible
76+
# to use one of the key words "stable", "preview" or "snapshot" see Composer
77+
# documentation.
78+
# To reinstall Composer after the image was built, run "ddev debug refresh".
79+
80+
# nodejs_version: "16"
81+
# change from the default system Node.js version to another supported version, like 12, 14, 17, 18.
82+
# Note that you can use 'ddev nvm' or nvm inside the web container to provide nearly any
83+
# Node.js version, including v6, etc.
84+
85+
# additional_hostnames:
86+
# - somename
87+
# - someothername
88+
# would provide http and https URLs for "somename.ddev.site"
89+
# and "someothername.ddev.site".
90+
91+
# additional_fqdns:
92+
# - example.com
93+
# - sub1.example.com
94+
# would provide http and https URLs for "example.com" and "sub1.example.com"
95+
# Please take care with this because it can cause great confusion.
96+
97+
# upload_dir: custom/upload/dir
98+
# would set the destination path for ddev import-files to <docroot>/custom/upload/dir
99+
# When mutagen is enabled this path is bind-mounted so that all the files
100+
# in the upload_dir don't have to be synced into mutagen
101+
102+
# working_dir:
103+
# web: /var/www/html
104+
# db: /home
105+
# would set the default working directory for the web and db services.
106+
# These values specify the destination directory for ddev ssh and the
107+
# directory in which commands passed into ddev exec are run.
108+
109+
# omit_containers: [db, dba, ddev-ssh-agent]
110+
# Currently only these containers are supported. Some containers can also be
111+
# omitted globally in the ~/.ddev/global_config.yaml. Note that if you omit
112+
# the "db" container, several standard features of ddev that access the
113+
# database container will be unusable. In the global configuration it is also
114+
# possible to omit ddev-router, but not here.
115+
116+
# nfs_mount_enabled: false
117+
# Great performance improvement but requires host configuration first.
118+
# See https://ddev.readthedocs.io/en/stable/users/performance/#using-nfs-to-mount-the-project-into-the-container
119+
120+
# mutagen_enabled: false
121+
# Performance improvement using mutagen asynchronous updates.
122+
# See https://ddev.readthedocs.io/en/latest/users/performance/#using-mutagen
123+
124+
# fail_on_hook_fail: False
125+
# Decide whether 'ddev start' should be interrupted by a failing hook
126+
127+
# host_https_port: "59002"
128+
# The host port binding for https can be explicitly specified. It is
129+
# dynamic unless otherwise specified.
130+
# This is not used by most people, most people use the *router* instead
131+
# of the localhost port.
132+
133+
# host_webserver_port: "59001"
134+
# The host port binding for the ddev-webserver can be explicitly specified. It is
135+
# dynamic unless otherwise specified.
136+
# This is not used by most people, most people use the *router* instead
137+
# of the localhost port.
138+
139+
# host_db_port: "59002"
140+
# The host port binding for the ddev-dbserver can be explicitly specified. It is dynamic
141+
# unless explicitly specified.
142+
143+
# phpmyadmin_port: "8036"
144+
# phpmyadmin_https_port: "8037"
145+
# The PHPMyAdmin ports can be changed from the default 8036 and 8037
146+
147+
# host_phpmyadmin_port: "8036"
148+
# The phpmyadmin (dba) port is not normally bound on the host at all, instead being routed
149+
# through ddev-router, but it can be specified and bound.
150+
151+
# mailhog_port: "8025"
152+
# mailhog_https_port: "8026"
153+
# The MailHog ports can be changed from the default 8025 and 8026
154+
155+
# host_mailhog_port: "8025"
156+
# The mailhog port is not normally bound on the host at all, instead being routed
157+
# through ddev-router, but it can be bound directly to localhost if specified here.
158+
159+
# webimage_extra_packages: [php7.4-tidy, php-bcmath]
160+
# Extra Debian packages that are needed in the webimage can be added here
161+
162+
# dbimage_extra_packages: [telnet,netcat]
163+
# Extra Debian packages that are needed in the dbimage can be added here
164+
165+
# use_dns_when_possible: true
166+
# If the host has internet access and the domain configured can
167+
# successfully be looked up, DNS will be used for hostname resolution
168+
# instead of editing /etc/hosts
169+
# Defaults to true
170+
171+
# project_tld: ddev.site
172+
# The top-level domain used for project URLs
173+
# The default "ddev.site" allows DNS lookup via a wildcard
174+
# If you prefer you can change this to "ddev.local" to preserve
175+
# pre-v1.9 behavior.
176+
177+
# ngrok_args: --basic-auth username:pass1234
178+
# Provide extra flags to the "ngrok http" command, see
179+
# https://ngrok.com/docs#http or run "ngrok http -h"
180+
181+
# disable_settings_management: false
182+
# If true, ddev will not create CMS-specific settings files like
183+
# Drupal's settings.php/settings.ddev.php or TYPO3's AdditionalConfiguration.php
184+
# In this case the user must provide all such settings.
185+
186+
# You can inject environment variables into the web container with:
187+
# web_environment:
188+
# - SOMEENV=somevalue
189+
# - SOMEOTHERENV=someothervalue
190+
191+
# no_project_mount: false
192+
# (Experimental) If true, ddev will not mount the project into the web container;
193+
# the user is responsible for mounting it manually or via a script.
194+
# This is to enable experimentation with alternate file mounting strategies.
195+
# For advanced users only!
196+
197+
# bind_all_interfaces: false
198+
# If true, host ports will be bound on all network interfaces,
199+
# not just the localhost interface. This means that ports
200+
# will be available on the local network if the host firewall
201+
# allows it.
202+
203+
# default_container_timeout: 120
204+
# The default time that ddev waits for all containers to become ready can be increased from
205+
# the default 120. This helps in importing huge databases, for example.
206+
207+
#web_extra_exposed_ports:
208+
#- name: nodejs
209+
# container_port: 3000
210+
# http_port: 2999
211+
# https_port: 3000
212+
#- name: something
213+
# container_port: 4000
214+
# https_port: 4000
215+
# http_port: 3999
216+
# Allows a set of extra ports to be exposed via ddev-router
217+
# The port behavior on the ddev-webserver must be arranged separately, for example
218+
# using web_extra_daemons.
219+
# For example, with a web app on port 3000 inside the container, this config would
220+
# expose that web app on https://<project>.ddev.site:9999 and http://<project>.ddev.site:9998
221+
# web_extra_exposed_ports:
222+
# - container_port: 3000
223+
# http_port: 9998
224+
# https_port: 9999
225+
226+
#web_extra_daemons:
227+
#- name: "http-1"
228+
# command: "/var/www/html/node_modules/.bin/http-server -p 3000"
229+
# directory: /var/www/html
230+
#- name: "http-2"
231+
# command: "/var/www/html/node_modules/.bin/http-server /var/www/html/sub -p 3000"
232+
# directory: /var/www/html
233+
234+
# override_config: false
235+
# By default, config.*.yaml files are *merged* into the configuration
236+
# But this means that some things can't be overridden
237+
# For example, if you have 'nfs_mount_enabled: true'' you can't override it with a merge
238+
# and you can't erase existing hooks or all environment variables.
239+
# However, with "override_config: true" in a particular config.*.yaml file,
240+
# 'nfs_mount_enabled: false' can override the existing values, and
241+
# hooks:
242+
# post_start: []
243+
# or
244+
# web_environment: []
245+
# or
246+
# additional_hostnames: []
247+
# can have their intended affect. 'override_config' affects only behavior of the
248+
# config.*.yaml file it exists in.
249+
250+
# Many ddev commands can be extended to run tasks before or after the
251+
# ddev command is executed, for example "post-start", "post-import-db",
252+
# "pre-composer", "post-composer"
253+
# See https://ddev.readthedocs.io/en/stable/users/extend/custom-commands/ for more
254+
# information on the commands that can be extended and the tasks you can define
255+
# for them. Example:
256+
#hooks:

Diff for: .env.example.dev

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# The application ID used to to uniquely store session and cache data, mutex locks, and more
2+
CRAFT_APP_ID=
3+
4+
# The environment Craft is currently running in (dev, staging, production, etc.)
5+
CRAFT_ENVIRONMENT=dev
6+
7+
# The secure key Craft will use for hashing and encrypting data
8+
CRAFT_SECURITY_KEY=
9+
10+
# Database connection settings
11+
CRAFT_DB_DRIVER=mysql
12+
CRAFT_DB_SERVER=127.0.0.1
13+
CRAFT_DB_PORT=3306
14+
CRAFT_DB_DATABASE=
15+
CRAFT_DB_USER=root
16+
CRAFT_DB_PASSWORD=
17+
CRAFT_DB_SCHEMA=public
18+
CRAFT_DB_TABLE_PREFIX=
19+
20+
# General settings (see config/general.php)
21+
DEV_MODE=true
22+
ALLOW_ADMIN_CHANGES=true
23+
DISALLOW_ROBOTS=true

Diff for: .env.example.production

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# The application ID used to to uniquely store session and cache data, mutex locks, and more
2+
CRAFT_APP_ID=
3+
4+
# The environment Craft is currently running in (dev, staging, production, etc.)
5+
CRAFT_ENVIRONMENT=production
6+
7+
# The secure key Craft will use for hashing and encrypting data
8+
CRAFT_SECURITY_KEY=
9+
10+
# Database connection settings
11+
CRAFT_DB_DRIVER=mysql
12+
CRAFT_DB_SERVER=127.0.0.1
13+
CRAFT_DB_PORT=3306
14+
CRAFT_DB_DATABASE=
15+
CRAFT_DB_USER=root
16+
CRAFT_DB_PASSWORD=
17+
CRAFT_DB_SCHEMA=public
18+
CRAFT_DB_TABLE_PREFIX=
19+
20+
# General settings (see config/general.php)
21+
DEV_MODE=false
22+
ALLOW_ADMIN_CHANGES=false
23+
DISALLOW_ROBOTS=false

Diff for: .env.example.staging

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# The application ID used to to uniquely store session and cache data, mutex locks, and more
2+
CRAFT_APP_ID=
3+
4+
# The environment Craft is currently running in (dev, staging, production, etc.)
5+
CRAFT_ENVIRONMENT=staging
6+
7+
# The secure key Craft will use for hashing and encrypting data
8+
CRAFT_SECURITY_KEY=
9+
10+
# Database connection settings
11+
CRAFT_DB_DRIVER=mysql
12+
CRAFT_DB_SERVER=127.0.0.1
13+
CRAFT_DB_PORT=3306
14+
CRAFT_DB_DATABASE=
15+
CRAFT_DB_USER=root
16+
CRAFT_DB_PASSWORD=
17+
CRAFT_DB_SCHEMA=public
18+
CRAFT_DB_TABLE_PREFIX=
19+
20+
# General settings (see config/general.php)
21+
DEV_MODE=false
22+
ALLOW_ADMIN_CHANGES=false
23+
DISALLOW_ROBOTS=true

Diff for: .gitignore

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
/.env
2+
/.idea
3+
/vendor
4+
.DS_Store

Diff for: .gitmodules

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[submodule "vendor-local/apple-news"]
2+
path = vendor-local/apple-news
3+
url = https://github.com/craftcms/apple-news.git

Diff for: bootstrap.php

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<?php
2+
/**
3+
* Shared bootstrap file
4+
*/
5+
6+
// Define path constants
7+
define('CRAFT_BASE_PATH', __DIR__);
8+
define('CRAFT_VENDOR_PATH', CRAFT_BASE_PATH . '/vendor');
9+
10+
// Load Composer's autoloader
11+
require_once CRAFT_VENDOR_PATH . '/autoload.php';
12+
13+
// Load dotenv?
14+
if (class_exists(Dotenv\Dotenv::class)) {
15+
// By default, this will allow .env file values to override environment variables
16+
// with matching names. Use `createUnsafeImmutable` to disable this.
17+
Dotenv\Dotenv::createUnsafeMutable(CRAFT_BASE_PATH)->safeLoad();
18+
}

Diff for: composer.json

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"require": {
3+
"craftcms/cms": "^4.2.0.2",
4+
"vlucas/phpdotenv": "^5.4.0"
5+
},
6+
"require-dev": {
7+
"sandersander/composer-link": "^0.3.1",
8+
"yiisoft/yii2-shell": "^2.0.3"
9+
},
10+
"autoload": {
11+
"psr-4": {
12+
"modules\\": "modules/"
13+
}
14+
},
15+
"config": {
16+
"allow-plugins": {
17+
"craftcms/plugin-installer": true,
18+
"yiisoft/yii2-composer": true,
19+
"sandersander/composer-link": true
20+
},
21+
"sort-packages": true,
22+
"optimize-autoloader": true,
23+
"platform": {
24+
"php": "8.0.2"
25+
}
26+
},
27+
"scripts": {
28+
"post-root-package-install": [
29+
"@php -r \"file_exists('.env') || copy('.env.example.dev', '.env');\""
30+
]
31+
}
32+
}

0 commit comments

Comments
 (0)