Skip to content

About

One-command bash script that spins up disposable TYPO3 instances on DDEV.

Resources

Contributing

Stars

12 stars

Watchers

0 watching

Forks

Latest commit

 

History

100 Commits

Folders and files

Repository files navigation

TYPO3 9.5 TYPO3 10.4 TYPO3 11.5
TYPO3 12.4 TYPO3 13.4 TYPO3 14.3 TYPO3 15 dev
Bash License: MIT Docker DDEV

typo3quickstarter

One-command bash script that spins up disposable TYPO3 instances on DDEV. Pick a version (or let it grab the latest), and it configures DDEV, installs TYPO3 via Composer, sets up the database and an admin user, drops the credentials into a local file, and opens the backend in your browser.

Built because roughly half of all TYPO3 sites out there are still running on old major versions — this makes it trivial to spin up several versions side by side and see what actually changed.

Got an idea for a feature, or found a bug? Open an issue - feature requests are welcome, not just bug reports.

typo3quickstarter demo

☕ Enjoying typo3quickstarter?

Support the development and keep the updates coming. Even 1€ helps :)

Buy me a coffee at ko-fi.com

Tip

New in 0.5.0: you can install typo3quickstarter system-wide now and run it from any directory — the instance is created wherever you happen to be. Keep it current with typo3quickstarter update. See Installation.

Prerequisites

The script checks for both and bails out early with a clear error if either is missing or Docker isn't running.

Installation

curl -fsSL https://raw.githubusercontent.com/pagea-dev/typo3quickstarter/main/install.sh | bash

That installs typo3quickstarter — plus t3quickstarter as a short alias — into ~/.local/bin. From then on you create instances wherever you happen to be:

cd ~/projects/project-x
typo3quickstarter --release=13

Updating is the same command again; removing it is typo3quickstarter-uninstall. See docs/installation.md for the install location and everything around it.

Other ways to install — from a checkout, or the single file with no install at all

From a checkout, which also gets you docs/, CHANGELOG.md and everything else:

git clone https://github.com/pagea-dev/typo3quickstarter.git
cd typo3quickstarter
./install.sh

Without installing anything, as a single file you run from where it lies — no other dependencies beyond bash, docker and ddev:

curl -LO https://github.com/pagea-dev/typo3quickstarter/releases/latest/download/typo3-ddev-setup.sh && chmod +x typo3-ddev-setup.sh
./typo3-ddev-setup.sh --release=13

Every flag works the same either way. Run this way, the script prints ./typo3-ddev-setup.sh back at you instead of typo3quickstarter wherever it suggests a follow-up command.

Usage

typo3quickstarter --release=13

No --release? It defaults to the newest supported major version:

typo3quickstarter

That's it. The script will:

  1. Create a project folder named e.g. typo3-v13-101 (or use --name if you gave one)
  2. Run ddev config with the right PHP version for that TYPO3 release
  3. Install TYPO3 with Composer inside the container, pinned to the release you asked for
  4. Run the non-interactive TYPO3 setup (database, admin user, default site)
  5. Write the login details to typo3-credentials.txt in the project folder
  6. Open /typo3 (the backend) in your browser via ddev launch

At the end you'll see something like:

==> Done.
URL:         https://typo3-v13-101.ddev.site
Backend:     https://typo3-v13-101.ddev.site/typo3
Admin:       admin
Password:    q7-Xf#2vRt%Ls9BkPz4m
Credentials: /home/you/projects/typo3-v13-101/typo3-credentials.txt
For ports, database and Mailpit details: 'ddev describe' inside /home/you/projects/typo3-v13-101
To clean up this instance: typo3quickstarter --c 101

The very first time DDEV adds a new *.ddev.site hostname to your system, it needs sudo to update /etc/hosts — you'll get a normal password prompt for that. It only happens once per hostname.

Commands

Command Description
typo3quickstarter update Check GitHub for a newer release and install it after asking
typo3quickstarter uninstall Remove the installed command, its alias and the uninstaller

Both only apply to a copy installed with install.sh — see docs/installation.md. Every normal run also checks for a newer release and prints a one-line notice under the banner if there is one; it never asks or installs anything, and TYPO3QUICKSTARTER_NO_UPDATE_CHECK=1 turns it off.

Options

Flag Description Default
-r=N, --release=N TYPO3 version to install — see docs/versions.md highest supported
--php-version=X.Y PHP version for the web container — see docs/versions.md per release line
--database=TYPE:VER Database server, mariadb:<version> or mysql:<version> — see docs/versions.md DDEV's default
--name=NAME DDEV project name auto-generated, e.g. typo3-v13-101
--path=DIR Where the project folder is created (also used by --cleanup) current directory
--admin-user, --admin-password, --admin-email Admin backend user — see docs/backend-users.md admin / random / admin@<project>.ddev.site
--require=PKG Install extra Composer packages after setup — see docs/composer-packages.md —
--require-dev=PKG Install extra Composer packages after setup as development dependencies — see docs/composer-packages.md —
--extension=PATH Mount and require a local extension for development — see docs/composer-packages.md —
--env=KEY=VALUE Set environment variables in the web container — see docs/environment-variables.md —
--xdebug Enable Xdebug for PHP step debugging from the first start — see docs/xdebug.md off
--no-pma Skip phpMyAdmin, which is installed by default — see docs/phpmyadmin.md off
--list List all instances this script created — see docs/instances.md —
--cleanup, --clear, --c [TARGET...] Interactively remove previously created instances, optionally narrowed down to name/ID matches — see docs/instances.md —
-v, --verbose Also write the full console output to verbose.log — see docs/verbose-logging.md —
--with-git After setup, ask whether to git init the whole project or scaffold and version a new extension — see docs/with-git.md —
--create-extension After setup, run the extension kickstarter and install the new extension from packages/ — see docs/create-extension.md —
-h, --help Show usage —
--version Show the script's own version — see docs/information.md —

More examples

The examples below use the installed command. Every one of them works just as well with ./typo3-ddev-setup.sh if you'd rather keep the single file around as a portable copy — on a USB stick, in a project folder, or on a machine you don't want to install anything on. Nothing is stored outside the instance folder either way.

Latest TYPO3 14 with a couple of extensions and a personal admin login, in one command:

typo3quickstarter --release=14 --require=b13/container georgringer/news --admin-user=lukas --admin-password='Correct-Horse-1' --admin-email=lukas@example.com

An exact TYPO3 12 patch release, plus a specific version of an extension (--require takes any Composer constraint, same as composer require vendor/package:constraint):

typo3quickstarter --release=12.4.20 --require=georgringer/news:^11.0

Kickstart a brand-new extension against the newest TYPO3, then put just that extension under git once it's created:

typo3quickstarter --with-git

Pick option 2 when asked, follow the kickstarter's prompts, and you'll have a working TYPO3 instance plus a freshly versioned extension - see docs/with-git.md.

Why

  • One command, zero clicking through the install wizard. No more re-typing DB credentials or admin passwords by hand.
  • Test against multiple TYPO3 versions in parallel. Each instance gets its own name, its own DDEV project, its own URL.
  • Disposable by design. Spin one up, break it, tear it down. --cleanup gets rid of the mess for you.
  • Kickstart a brand-new extension and have it under git from the first commit. --with-git runs the official TYPO3 extension kickstarter, then initializes a repository right where it just created your extension - a working TYPO3 instance, a scaffolded extension, and its own git history, from a single command. See docs/with-git.md.

Documentation

Contributing

Sending a PR? Please read docs/CONTRIBUTING.md first - in short: branch from the current version branch, not main (PRs against main are ignored), test the script for real before opening the PR, and keep the executable bit intact.

Compatibility

Actively tested on Ubuntu-based Linux (e.g. Zorin OS) and Windows via WSL. Should work anywhere bash, docker, and ddev do, but hasn't been verified elsewhere.

macOS isn't tested or supported yet - happy to take a PR from someone who wants to develop and test it there (see docs/CONTRIBUTING.md).

Notes

  • typo3-credentials.txt is written outside the public/ docroot, so it's never reachable over HTTP, and it gets chmod 600 plus an entry in .gitignore automatically. verbose.log (with --verbose) gets the same treatment.

Special thanks

This project stands entirely on the shoulders of others' work:

Thanks to everyone building and maintaining these projects.

License

MIT — see LICENSE.

About

One-command bash script that spins up disposable TYPO3 instances on DDEV.

Resources

Contributing

Stars

12 stars

Watchers

0 watching

Forks

Releases

Contributors

Languages