chore: fileadmin is a shared dir of the TYPO3 13 deployment

fileadmin moves from the TYPO3 10 release
(ep-reisen-typo3/shared/public/fileadmin) to
ep-reisen-typo3-13/shared/public/fileadmin, so Deployer links it like the
other shared dirs (relative symlink) and the typo3:fileadmin task with
its absolute fileadmin_path goes.

deploy:shared creates a missing shared dir empty, which would leave the
sites without any file: deploy:check:fileadmin aborts the deploy before
anything happens on the server if the shared fileadmin is missing. Deploy
this only after the directory has been moved.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
frommeandClaude Opus 5.5 committed 2026-10-26 09:48:17 +01:00
1 parent ff45147964
commit 4a3ef91dd0
1 file changed
+7 -7
+7 -7
View File
@@ -11,10 +11,8 @@ set('cachetool_url', 'https://github.com/gordalina/cachetool/releases/download/1
set('application', 'ep-reisen-typo3-13');
set('keep_releases', 3);
// fileadmin of the TYPO3 10 release until it is moved into shared/ (plan 4a, tidy up step 2)
set('fileadmin_path', '/usr/home/eptypo3/public_html/ep-reisen-typo3/shared/public/fileadmin');
set('shared_dirs', [
'{{typo3/public_dir}}/fileadmin',
'{{typo3/public_dir}}/typo3temp/assets',
'var/lock',
'var/log',
@@ -91,9 +89,11 @@ task('deploy:build', function () {
runLocally('ddev exec bash -c "cd var/deploy-build && composer install --no-dev --prefer-dist --no-progress --no-interaction --optimize-autoloader"');
})->once();
task('typo3:fileadmin', function () {
// Relative (-r), like Deployer's shared dirs: the vhosts answer 403 for an absolute symlink here
run('ln -sfnr {{fileadmin_path}} {{release_path}}/{{typo3/public_dir}}/fileadmin');
// deploy:shared would create a missing shared dir empty, and the sites would lose every file
task('deploy:check:fileadmin', function () {
if (!test('[ -d {{deploy_path}}/shared/{{typo3/public_dir}}/fileadmin ]')) {
throw new \RuntimeException(parse('{{deploy_path}}/shared/{{typo3/public_dir}}/fileadmin is missing'));
}
});
// current_path instead of the recipe's release_path, so it also works after a rollback
@@ -103,6 +103,7 @@ task('typo3:cache:flush', function () {
task('deploy', [
'deploy:info',
'deploy:check:fileadmin',
// Build locally first, so a failing build aborts before the server is touched at all.
'deploy:build',
'deploy:setup',
@@ -110,7 +111,6 @@ task('deploy', [
'deploy:release',
'rsync',
'deploy:shared',
'typo3:fileadmin',
'deploy:writable',
// The schema has to exist before the new code starts serving traffic.
'typo3:extension:setup',