Commit 481caa67 authored by Joachim Mathes's avatar Joachim Mathes

TASK: Update documentation

parent d2c318be
Deployment
==========
For deployment you need to have access to `vpro0100.proserver.punkt.de` as user `proserver`.
Thus, your public key has to be provided. Please inform one of the already registered users
or ask technik@punkt.de if you need access.
Login as user `proserver` to allow agent forwarding. Login as user `vagrant` and sudo to `proserver` won't work!
Run `vagrant ssh-config` to find the private key path of user `vagrant`. The result will look somehow like this:
```
/Users/<USER>/projects/typo3.org > vagrant ssh-config
Host default
HostName 127.0.0.1
User vagrant
Port 2222
UserKnownHostsFile /dev/null
StrictHostKeyChecking no
PasswordAuthentication no
IdentityFile /Users/<USER>/.vagrant.d/insecure_private_key
IdentitiesOnly yes
LogLevel FATAL
ForwardAgent yes
```
Line `IdentityFile` is what you need. A more sophisticated way to get the path would be:
```
vagrant ssh-config | grep IdentityFile | awk '{print $2}'
```
Then run
```
ssh -A -i /Users/<USER>/.vagrant.d/insecure_private_key proserver@172.17.28.100
```
and go to
```
cd /var/www/t3o
```
Finally it's surf, which will deploy the application to `vpro0100.proserver.punkt.de`:
```
php surf.phar deploy production
```
Installation
============
Go to your project directory and run `fab initialize_proserver_box`. It
1. downloads a generic proServer vagrant box from punkt.de and boots it.
2. puts the public key of box user `vagrant` to box user `proserver`.
3. injects the project from your host's workspace into the box.
4. runs composer to initialize the project.
The `composer` run will be interrupted and ask you for `username` and `password` of
your `typo3.org` account to download `t3o/t3olayout`.
```
[172.17.28.100] out: - Installing typo3/cms (8.6.0) Downloading: 100%
[172.17.28.100] out: - Installing symfony/process (v3.2.4) Downloading: 100%
[172.17.28.100] out: - Installing helhum/typo3-console (4.2.0) Downloading: 100%
[172.17.28.100] out: - Installing t3o/t3olayout (dev-template 45671db) Authentication required (git-t3o.typo3.org):
[172.17.28.100] out: Username:
[172.17.28.100] out: Password:
```
Enter valid credentials and the installation will continue.
5. downloads and imports the `t3o` database from `vpro0100.proserver.punkt.de`.
6. restarts `php-fpm`
7. downloads the initialized project from the box to your hosts's workspace.
PhpStorm
========
Prepare your PhpStorm for continuous deployment of your code changes into the box.
We prefer deployment, due to massive performance issues with NFS mounts.
1. Enter the _Settings_ menu.
2. Search _Deployment_
3. Add a deployment configuration by klicking the plus icon.
4. Name it `t3o`, for example.
Connection configuration
------------------------
![PhpStorm deployment connection][connection]
* If you don't know the path to vagrant's private key file run `vagrant ssh-config | grep IdentityFile | awk '{print $2}'`.
* Make sure to the _Test SFTP connection_.
Mapping configuration
---------------------
![PhpStorm deployment mappings][mappings]
Options configuration
---------------------
![PhpStorm deployment options][options]
* Make sure to activate _Upload external changes_, so file changes induced by `grunt` will be recognized as well.
[connection]: https://gitlab.pluspunkthosting.de/T3O/typo3.org/blob/master/documentation/phpstorm/deployment_connection.png "PhpStorm deployment connection"
[mappings]: https://gitlab.pluspunkthosting.de/T3O/typo3.org/blob/master/documentation/phpstorm/deployment_mappings.png "PhpStorm deployment mappings"
[options]: https://gitlab.pluspunkthosting.de/T3O/typo3.org/blob/master/documentation/phpstorm/deployment_options.png "PhpStorm deployment options"
Prerequisites
=============
* [VirtualBox](https://www.virtualbox.org)
* [Vagrant](https://www.vagrantup.com)
* [Python 2.7](https://www.python.org)
* [fabric](http://www.fabfile.org)
The box is tested with
* VirtualBox 4.3.40 and 4.3.30
* Vagrant 1.8.5 and 1.6.3
* Python 2.7
* Fabric 1.11.1 with Paramiko 1.16.0
but should work with current versions. Please [let us know](technik@punkt.de), if any problems occur.
Installation
------------
Use your system specific package management system like `brew` on MacOS or `apt-get` on Linux
to install the respective packages. `fabric` can also be installed via python's `pip`:
```
sudo pip install fabric
```
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment