517 Commits

Author SHA1 Message Date
Simon Sprankel
cfc3ecbde4
Fix formatting (#2443)
* Fix formatting

* Fix formatting
2021-03-05 11:51:18 +01:00
Peter Jaap Blaakmeer
d7d5a01674
Remove config/jwt from writable dirs list (#2430)
config/jwt should have chmod 600, not 755
2021-02-23 17:11:08 +01:00
Fabian Blechschmidt
f5c9a92b1d
Feature/2423 shopware order modules (#2425)
* #2423 shopware: task sw:plugin:activate:all runs migration script in wrong order

- add dependency for polyfill (to use str_ends_with)
- marcj/topsort (for sorting the shopware modules)

* #2423 shopware: task sw:plugin:activate:all runs migration script in wrong order

- get the plugin list
- read the composer names and dependencies from composer.lock
- order by dependencies
- use sorted list for activation and migration

* #2423 shopware: task sw:plugin:activate:all runs migration script in wrong order

Update changelog

* #2423 shopware: task sw:plugin:activate:all runs migration script in wrong order

do not update doc, but remove require autoload.php
2021-02-23 08:50:46 +01:00
Rick Schippers
c714d10356
Shopware recipe - fix invalid parsing of plugin:list and invoke nested sw:plugin:refresh instead of redefining it (#2419)
* Removed incorrect duplicate version column

* Invoke nested task instead of incorrectly redefining it, so it actually runs.

* Changelog updated
2021-02-19 11:45:15 +01:00
lukepass
367c9bf723
Local composer should take precedence over global composer (#2371)
Co-authored-by: Luca Passini <l.passini@melazeta.com>
2021-01-13 13:26:35 +03:00
Ash Davies
da432e0139
Warning message sentence correction (#2361)
Corrected warning message to read a little better.
2020-12-24 15:55:11 +03:00
Anton Medvedev
2a12046528 Remove composer_version option 2020-12-18 20:13:28 +01:00
Anton Medvedev
7283848cc6 Remove provision 2020-12-18 17:19:19 +01:00
Pascal Hubrecht
6d357e94b6
Safety to avoid modifying files outside deploy_path (#2284)
* Safety to avoid modifying files outside deploy_path

Using writable_dirs with writable_use_sudo can lead to a disaster on a server (example using /var/log instead of var/log as writable dir).

* Update writable.php

* Update CHANGELOG.md

* Update CHANGELOG.md

* Update writable.php

* trailing slash

* docgen

* throw exception if absolute path in writable dirs
2020-12-12 20:21:48 +01:00
Anton Medvedev
9296a5acc8
Sync content_version for magento assets between hosts. (#2293)
* Sync content_version for magento assets between hosts.

* Update docs
2020-12-08 00:02:08 +01:00
Anton Medvedev
e6b491b4ad Fix phpstan error 2020-11-15 23:52:48 +01:00
Anton Medvedev
c7542ec048 Update doc 2020-11-11 10:10:57 +01:00
Mikael Peigney
96dfc6cff6
Allow changing Composer channel (#2265)
Composer installer can now take an argument to select which version channel to use: https://github.com/composer/getcomposer.org/pull/156/files
This allows for exemple to stay on major version 1 without specifying a specific Composer version
2020-11-11 12:09:50 +03:00
Unai Lopez
d9340bd7f6
Magento 2 Zero downtime deployment (#2262)
* Magento2: look for database migrations in order to get zero downtime deployments when changes are not needed
- also keep maintenance status active in case it was already previously activated

* Magento2: adjust shared dirs

* Magento2: dump autoload before setup di compile
- fix for magento 2.4 deployments https://github.com/magento/magento2/issues/23251

* Magento2: force static content deploy
- avoids deployment failure when magento production mode is not set

* Magento2: update change log

* Magento2: update recipe docs

* Revert "Magento2: force static content deploy"

This reverts commit 45de3337a5a3e524685c422be3fbc6957fe6b480.

* Magento2: detect configuration changes, launch config import

* Magento2: refactor recipe
- make all tasks compatible with any magento 2 version (skip command execution if still does not exist in certain version)
- remove duplicated check on maintenance status
- remove catch for processFailedException

Co-authored-by: Unai Lopez <unai.lopez@vdshop.es>
Co-authored-by: Peter Jaap Blaakmeer <peterjaap@blaakmeer.com>
2020-11-11 01:36:38 +03:00
Anton Medvedev
2405241f2d Add timeout exceptions 2020-11-05 19:43:04 +01:00
Anton Medvedev
5c736c07d4 Refactor recipes 2020-10-29 23:16:36 +01:00
Anton Medvedev
c747a5945b Rename git_target to target 2020-10-28 00:12:18 +01:00
Sacharski Bartłomiej
9d725ede63
Implemented E2E tests for provision recipe (#2228)
Created new container using Ubuntu 20.04 as a base, for a E2E test
environment for the provision recipe.

Due to container sharing a kernel with host os, the firewall provisioning
had to be turn off during the testing procedure.
2020-10-27 00:22:53 +03:00
Anton Medvedev
ff110c987d
Refactor recipes (#2224) 2020-10-25 18:00:05 +03:00
Anton Medvedev
2feb5c1247 Update docs 2020-10-25 14:20:03 +01:00
Joey Kaan
ee3746690b
Add composer_version to choose which composer version to install (#2222)
Co-authored-by: Joey Kaan <joeyk@spotify.com>
2020-10-25 13:01:34 +01:00
Justinas Urbanavicius
a6edb7f977
fixed issue #2209 (#2211)
* fixed issue #2209

Copy shared files and folder should be verbose only when deployer is run with Very verbose output

* updated CHANGELOG.md

* changed to -vvv

* changes sprintf to interpolation
2020-10-22 13:56:20 +02:00
Andrey Helldar
9f89525548
[composer 3] Removed deprecated option "--no-suggest" (#2212)
* [composer 3] deprecated option "--no-suggest"

* Updated CHANGELOG.md

* Update CHANGELOG.md

Co-authored-by: Anton Medvedev <anton@medv.io>
2020-10-21 23:53:25 +02:00
bonswouar
f7fb577b34
[#2207] Symfony change dir to execute DoctrineMigrations (#2208)
Co-authored-by: bonswouar <contact@florianmessmer.com>
2020-10-17 11:07:22 +03:00
Anton Medvedev
10c8b0de8f Better dep init command 2020-10-16 22:54:20 +02:00
Anton Medvedev
daee77bf1f Update docs 2020-10-11 16:35:59 +02:00
Anton Medvedev
36596a618e Add dotenv support 2020-10-11 16:23:40 +02:00
Anton Medvedev
5bd53b8fc9 Added env test 2020-10-11 16:04:44 +02:00
Anton Medvedev
8e72449246 Add push task 2020-10-11 00:08:50 +02:00
Anton Medvedev
e227623ba6 Fix deploy:check_remote task 2020-10-10 21:58:06 +02:00
Anton Medvedev
6bea23bf02 Fix status command if release not a git repo 2020-10-10 20:38:32 +02:00
Anton Medvedev
f429c750bc Keep release on rollback and mark it as bad 2020-10-09 23:11:30 +02:00
Anton Medvedev
84c9f6bb58 Add status command 2020-10-09 02:24:09 +02:00
Anton Medvedev
c88ebe275f Allow to change current_path 2020-10-09 01:35:42 +02:00
Anton Medvedev
112601294c Fix shared dir with trailing slash 2020-10-09 01:14:16 +02:00
Anton Medvedev
a1103bee17 Migrate to common prepare/publish tasks 2020-10-08 01:53:45 +02:00
Anton Medvedev
71afcdcc3a Store composer.phar in .dep 2020-10-08 01:19:39 +02:00
Anton Medvedev
8cb0b39dc3 Switch deploy:shared and deploy:writable order 2020-10-08 00:45:12 +02:00
Anton Medvedev
a5e00c686a Copy shared dir only if there is no dir 2020-10-08 00:42:44 +02:00
Anton Medvedev
dafad94e8e Better error message for ACL 2020-10-08 00:41:18 +02:00
Anton Medvedev
d2c320ccf9 Ask password for deployer user 2020-10-08 00:35:30 +02:00
Anton Medvedev
744c56fc09 Refactor deploy:writable 2020-10-07 23:55:41 +02:00
Anton Medvedev
47a193f9af
Add docgen 2020-10-02 01:11:13 +03:00
Sacharski Bartłomiej
514d997c15
[issue-2170] Use on(localhost(), ...) instead of runLocally in check_remote.php (#2175)
Reworked the `deploy:check_remote` step, to use the `on(localhost(), ...)`,
instead of relying on `runLocally`.

This has been changed, to make sure that the all functions that
are being executed and are related to "local" part of the logic,
are ran on the local host.

Previously in `runLocally(sprintf("%s ls-remote $opt $repository $ref", get('bin/git')));`
the `get('bin/git')` would've been executed on the remote host, which
could have resulted in an unexpected behaviour.

By closing all of the instructions, in the closure that is executed
by the `on()` function, we are sure that the context is set to the
right host.
2020-10-01 20:32:51 +03:00
Joel Pittet
44f5f840c3
Laravel Task artisan:migrate should only run once (#2169)
Add once() again command that got dropped from the v7 updated commit.
2020-09-24 15:28:21 +02:00
kicaj
685e7cbd2c
Create cakephp4.php (#2167)
* Create cakephp4.php

* Update cakephp4.php
2020-09-21 14:51:34 +03:00
Peter Jaap Blaakmeer
c19b1dcae1
Add sw:plugin:activate:all and sw:plugin:migrate:all to Shopware 6 recipe (#2159)
Do not update upgradeable plugins, it updates code too. What we actually want is to run the migration. But the database:migrate --all command only runs the migrations for the core. Added a task that runs migrations for all plugins too.

Added || true to not let it fail on non-existing database migrations. This can be removed when this commit is released; 2a8a76fd83
2020-09-10 16:13:52 +02:00
Fabian Blechschmidt
f16e0cbad9
Update shopware6.php (#2158)
* Update shopware6.php

I'm not sure wether this is interesting for your @peterjaap I hacked a script with the horrible table output to install, upgrade and activate all plugins

* Update shopware6.php

made it a static function
2020-09-09 14:32:52 +02:00
Andreas Möller
96c739bd5b
Enhancement: Add deploy:is-unlocked (#2152) 2020-09-03 16:17:52 +03:00
Fabian Blechschmidt
d0c8cc1a79
Update shopware6.php (#2151)
* Update shopware6.php

Microoptimization

* Update shopware6.php

Run build with bash
FIXES   build.sh: 6: Bad substitution
2020-09-03 16:15:56 +03:00