Some checks failed
CI / build (snapshot, beta, 8.1) (push) Has been cancelled
CI / build (snapshot, beta, 8.2) (push) Has been cancelled
CI / build (snapshot, dev, 8.1) (push) Has been cancelled
CI / build (snapshot, dev, 8.2) (push) Has been cancelled
CI / build (snapshot, stable, 8.1) (push) Has been cancelled
CI / build (snapshot, stable, 8.2) (push) Has been cancelled
CI / build (snapshot, stable, 8.3) (push) Has been cancelled
CI / build (stable, beta, 8.1) (push) Has been cancelled
CI / build (stable, beta, 8.2) (push) Has been cancelled
CI / build (stable, dev, 8.1) (push) Has been cancelled
CI / build (stable, dev, 8.2) (push) Has been cancelled
CI / build (stable, stable, 8.1) (push) Has been cancelled
CI / build (stable, stable, 8.2) (push) Has been cancelled
CI / build (stable, stable, 8.3) (push) Has been cancelled
CI / test-composer (push) Has been cancelled
CI / build (snapshot, beta, 8.1) (pull_request) Has been cancelled
CI / build (snapshot, beta, 8.2) (pull_request) Has been cancelled
CI / build (snapshot, dev, 8.1) (pull_request) Has been cancelled
CI / build (snapshot, dev, 8.2) (pull_request) Has been cancelled
CI / build (snapshot, stable, 8.1) (pull_request) Has been cancelled
CI / build (snapshot, stable, 8.2) (pull_request) Has been cancelled
CI / build (snapshot, stable, 8.3) (pull_request) Has been cancelled
CI / build (stable, beta, 8.1) (pull_request) Has been cancelled
CI / build (stable, beta, 8.2) (pull_request) Has been cancelled
CI / build (stable, dev, 8.1) (pull_request) Has been cancelled
CI / build (stable, dev, 8.2) (pull_request) Has been cancelled
CI / build (stable, stable, 8.1) (pull_request) Has been cancelled
CI / build (stable, stable, 8.2) (pull_request) Has been cancelled
CI / build (stable, stable, 8.3) (pull_request) Has been cancelled
CI / test-composer (pull_request) Has been cancelled
68 lines
3.1 KiB
Markdown
68 lines
3.1 KiB
Markdown
# Composer template for Drupal projects
|
||
|
||
[](https://github.com/drupal-composer/drupal-project/actions/workflows/ci.yml)
|
||

|
||
|
||
**Based on [Drupal Composer](https://github.com/drupal-composer/drupal-project/tree/10.x)**
|
||
|
||
## What does the template do?
|
||
|
||
* Drupal will be installed in the `web` directory.
|
||
* Generated composer autoloader `vendor/autoload.php` is used instead of
|
||
`web/vendor/autoload.php` provided by Drupal core.
|
||
* Modules (packages of type `drupal-module`) will be placed in `web/modules/contrib` directory.
|
||
* Themes (packages of type `drupal-theme`) will be placed in `web/themes/contrib` directory.
|
||
* Profiles (packages of type `drupal-profile`) will be placed in `web/profiles/contrib` directory.
|
||
* Creates default writable versions of `settings.php` and `services.yml`.
|
||
* Creates `web/sites/default/files` directory.
|
||
* Drush is installed for use as `vendor/bin/drush`.
|
||
* Provides an [example](.env.example) of the `.env` file.
|
||
|
||
## Usage
|
||
Manual install instructions. Production deployments should be handled by the CI/CD runner automatically.
|
||
*Instructions for this to come later one I've actually built the flow.*
|
||
> [!NOTE]
|
||
> The Cram-A-Lot website does not currently support containerized deployments.
|
||
|
||
1. Clone the repository to the destination.
|
||
2. Install Dependencies
|
||
```bash
|
||
composer install
|
||
```
|
||
3. Configure your webserver's home dir to `{PROJECT_DIR}/web`
|
||
|
||
### Setup for development
|
||
It is recommended to [install DDEV.](https://ddev.readthedocs.io/en/latest/users/install/ddev-installation/)
|
||
Review the official [Drupal Local Development Guide](https://www.drupal.org/docs/official_docs/local-development-guide) for more information.
|
||
|
||
### Prerequisites
|
||
You must have WSL2 set up on your system with docker installed.
|
||
### Install DDEV
|
||
```bash
|
||
# Add DDEV’s GPG key to your keyring
|
||
sudo sh -c 'echo ""'
|
||
sudo apt-get update && sudo apt-get install -y curl
|
||
sudo install -m 0755 -d /etc/apt/keyrings
|
||
curl -fsSL https://pkg.ddev.com/apt/gpg.key | gpg --dearmor | sudo tee /etc/apt/keyrings/ddev.gpg > /dev/null
|
||
sudo chmod a+r /etc/apt/keyrings/ddev.gpg
|
||
|
||
# Add DDEV releases to your package repository
|
||
sudo sh -c 'echo ""'
|
||
echo "deb [signed-by=/etc/apt/keyrings/ddev.gpg] https://pkg.ddev.com/apt/ * *" | sudo tee /etc/apt/sources.list.d/ddev.list >/dev/null
|
||
|
||
# Update package information and install DDEV
|
||
sudo sh -c 'echo ""'
|
||
sudo apt-get update && sudo apt-get install -y ddev
|
||
|
||
# One-time initialization of mkcert
|
||
mkcert -install
|
||
```
|
||
### Starting the Dev Container
|
||
1. Clone this project, then open a terminal session to the new directory.
|
||
2. Run `ddev config --project-type drupal --docroot web`
|
||
3. Run `ddev composer install` then `ddev start`. Watch for the console to output a URL to access the webserver
|
||
|
||
## Contributing
|
||
If you're using this as a basis for a website, then please fork it first or change the origin after cloning.
|
||
Commits to the #main are blocked. Pull Requests will be rejected without good reason.
|