Code Monkey home page Code Monkey logo

joro-typo3reversedeployment's People

Contributors

chriwo avatar drblitz-weblab avatar koehnlein avatar ochorocho avatar spoonerweb avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

joro-typo3reversedeployment's Issues

Download of db-dump not working on 1&1 Server

Export DB: cd /kunden/homepages/XX/XXXXXXXXX/htdocs/staging/releases/current/html/ && php ../vendor/bin/typo3cms database:export 
rsync: change_dir "/kunden/homepages/XX/XXXXXXXXX/htdocs/staging/releases/current/html/typo3temp/joro_typo3reversedeployment" failed: No such file or directory (2)
rsync error: some files could not be transferred (code 23) at /BuildRoot/Library/Caches/com.apple.xbs/Sources/rsync/rsync-51/rsync/main.c(1404) [receiver=2.6.9]

When starting the reverser deployment on a 1&1-Server the error message above occurs and no database is being downloaded. Fileadmin works just fine.

After creating the asked directory joro_typo3reversedeployment in typo3temp folder, the download of the dump worked.

Detect path to typo3cms

At the moment, the typo3cms binary is only searched in ../vendor/bin. The deployment tool should support non-composer-based installations and automatically detect, if the binary is installed in composer mode or non-composer mode.

Use ddev if installed

It would be nice if ddev is used in the to do some nice stuff.
E.g. auto-import downloaded mysql-dump

Send keepAlive to SSH

Send keepAlive to make connection persist during long server side operations.

Seems like for security reasons some ssh servers do not send keepAlive to the client and therefore the connections is dropped after a certain time.

Run as binary and include config

According to TYPO3 Surf its possible to read a php file as configuration and execute via a php "binary"

like this:

typo3reverse myconfig

Add variable for php cli path

$sqlExport = "cd " . $this->getTypo3RootPath() . " && ../vendor/bin/typo3cms database:export";

On some servers we need to add the path to the php cli executable for typo3cms calls:

X-Powered-By: PHP/4.4.9
Content-type: text/html

This version of TYPO3 Console requires PHP 7.0.0 or above!
Your PHP version is: 4.4.9
Please specify a suitable PHP cli binary before the typo3cms binary like that:
/path/to/php70-latest ../vendor/bin/typo3cms

More configuration options for downloading files

It would be great to have more configuration options for downloading the files

  • download all files, ingnoring sys_file_reference
  • exclude folders (e.g. fileadmin/_processed_)
  • download additional folders with different names (e.g. /uploads)

Do not save remote SQL dump file in typo3temp

If the script will abort, the file keeps accessible via HTTP. Ideas to solve this:

  • Use ../ (relative to webroot) to save the dump. You require a composer folder structure to access typo3cms, so it should not be a problem to have write access to this root folder.
  • Dynamically create a dedicated folder inside typo3temp and automatically add a .htaccess file to protect files.
  • Let user configure the path.

Extend docs

  • Add detailed reqirements: typo3-console, rsync, typo3-composer install (> 8.7)
  • Explain features in Detail
  • Publish doxygen docs (via GitHub Pages)

Typo3 v12 compatibility

What does not work for you?
/vendor/bin/typo3cms is no longer a proper approach since it was removed...

What is your suggestion to fix/improve this?
...but from my testing the only change required was setting
$reverseDeploy->setPathToConsoleExecutable('../vendor/bin/typo3');
in reverse configuration file and so far it works flawlessly.

Fix path to LocalConfiguration.php

$remoteConf = $ssh->exec($this->getPhpPathAndBinary() . " -r 'echo file_get_contents(\"$path/typo3conf/LocalConfiguration.php\");'");

With the last change on this line, the reverse deployment tool can't fetch the LocalConfiguration.php file.

Error Message:
PHP Parse error: syntax error, unexpected 'in' (T_STRING) in /[...]/vendor/joro/typo3reversedeployment/JoRo/Typo3ReverseDeployment.php(404) : eval()'d code on line 1

The old implementation $remoteConf = $ssh->exec('cat ' . $path . '/typo3conf/LocalConfiguration.php'); works.

Update Readme

  1. Use correct calls:
$reverseDeploy->setFileTarget("./fileadmin/");
$reverseDeploy->getFiles($ssh);
  1. Use more generic example data for username and host

  2. You can use exact file name ./folder/dump.sql in setSqlTarget function or you use a folder ./dump/, wich results in generic file names like 2018031336-db722877585.sql

Update php dependency

What does not work for you?

image

How do you think it should work?

It should work with newer php versions

What is your suggestion to fix/improve this?

Check compatibility and raise php dependencies in composer.json

Respect TYPO3_CONTEXT

The environment variable should be configurable and if set, it should be prepended to all php commands.

And when reading the local configuration, the file AdditionalConfiguration.php should be included, to get the correct settings.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.