Skip to content

[FEATURE] Add command "init" to configure platform install for legacy bridge usage#147

Merged
andrerom merged 12 commits into
1.5from
also_symlink_extension_folder
Feb 26, 2019
Merged

[FEATURE] Add command "init" to configure platform install for legacy bridge usage#147
andrerom merged 12 commits into
1.5from
also_symlink_extension_folder

Conversation

@andrerom
Copy link
Copy Markdown
Contributor

@andrerom andrerom commented Apr 10, 2018

In order to simplify upgrades from pure legacy installs, this command is meant to be used like this to simplify install / upgrades (in comparison to todays INSTALL.md, which does not cover upgrades, and is a bit more manual still):

  • Enable bundle(s)
  • (Optional) Edit config for legacy routes, & enable legacy mode for backend
  • Install legacy bridge
  • Run init which will:
    • Generate all legacy related folders, and tell you which one is which and where to copy your files from eZ Publish
    • Adjust composer.json as current described in INSTALL doc automatically ?
      • Add the composer legacy post-*-scripts
      • Enable EzPublishLegacyBundle
      • Add legacy routes
      • Optional: Enable legacy_mode for your backoffice siteaccess
      • Optional: add security rules for the Setup Wizard
      • Optional: Ask user to install recommended extensions / bundles (search ext, richtext ext, ..)
      • Instruct user to run composer run-script post-update-cmd once things have been moved into folders, or maybe rather composer legacy-scripts
  • Update INSTALL doc to reflect usage of this command.

@andrerom andrerom requested review from emodric and vidarl April 10, 2018 09:34
@andrerom andrerom changed the base branch from master to 1.4 April 10, 2018 09:34
@andrerom andrerom force-pushed the also_symlink_extension_folder branch from c08267e to ab43a22 Compare April 10, 2018 10:17
@emodric

This comment has been minimized.

@andrerom

This comment has been minimized.

@emodric

This comment has been minimized.

@andrerom andrerom force-pushed the also_symlink_extension_folder branch from ab43a22 to 0b06e0d Compare April 23, 2018 21:49
@andrerom

This comment has been minimized.

@andrerom andrerom force-pushed the also_symlink_extension_folder branch from 0b06e0d to 103870d Compare April 23, 2018 22:01
@ezsystems ezsystems deleted a comment from ezrobot Apr 23, 2018
@andrerom
Copy link
Copy Markdown
Contributor Author

@emodric what do you think?

ref:
bin/console ezpublish:legacy:init --help

"Inits folders you can use when migrating from eZ Publish install to eZ Platform with Legacy Bridge"

Copy link
Copy Markdown
Collaborator

@emodric emodric left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good (with one minor remark about spelling). What is missing is some docs on the intended usage workflow (init and then symlink?).

Comment thread bundle/Command/LegacyInitCommand.php Outdated
<<<EOT
The command <info>%command.name%</info> creates the following folders for migration usage:
- src/AppBundle/ezpublish_legacy => Optionaly for extensions you want to version in your project source (as opposed to install using composer)
- src/legacy_files/design => Optionally for cusotm designs not already made part of an extension
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

custom

@andrerom andrerom changed the title [ezpublish:legacy:symlink] Also support symlinking extension folders [WIP] Add command "init" to creating folder structure legacy bridge usage May 14, 2018
@andrerom andrerom changed the title [WIP] Add command "init" to creating folder structure legacy bridge usage [RFC] Add command "init" to creating folder structure legacy bridge usage May 14, 2018
@andrerom
Copy link
Copy Markdown
Contributor Author

@emodric PR description updated to reflect better the overall workflow I'm suggesting here.

This might be something @vidarl, @crevillo, @joekepley and @peterkeung might want to give input on as well here.

@andrerom andrerom force-pushed the also_symlink_extension_folder branch from e348452 to 2bfe4ce Compare June 29, 2018 10:16
@andrerom andrerom changed the title [RFC] Add command "init" to creating folder structure legacy bridge usage [WIP] Add command "init" to creating folder structure legacy bridge usage Jun 29, 2018
@vidarl
Copy link
Copy Markdown
Member

vidarl commented Oct 25, 2018

Implemented "Adjust composer.json as current described in INSTALL doc automatically"...

@ezsystems ezsystems deleted a comment from ezrobot Oct 25, 2018
$updateComposerJson = true;
} elseif (!in_array('@legacy-scripts', $composerJson['scripts']['symfony-scripts'])) {
$symfonyScripts = $composerJson['scripts']['symfony-scripts'];
$offset = array_search('@php bin/console assetic:dump', $symfonyScripts);

This comment was marked as resolved.

Comment thread bundle/Command/LegacyInitCommand.php Outdated
legacy install:
- <info>ezpublish:legacy:symlink</info>
- <info>ezpublish:legacybundles:install_extensions</info>
- <info>ezpublish:legacy:assets_install</info>
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

these can now be changed to composer legacy-scripts

}

if (!array_key_exists('symfony-scripts', $composerJson['scripts'])) {
$composerJson['scripts']['symfony-scripts'] = ['@legacy-scripts'];

This comment was marked as resolved.

@vidarl vidarl force-pushed the also_symlink_extension_folder branch from 89fcfce to 217b792 Compare October 29, 2018 13:02
@ezsystems ezsystems deleted a comment from ezrobot Oct 29, 2018
@andrerom andrerom changed the base branch from 1.4 to 1.5 February 18, 2019 13:01
@andrerom andrerom force-pushed the also_symlink_extension_folder branch from 9516554 to 1280828 Compare February 18, 2019 13:02
@ezrobot

This comment has been minimized.

@andrerom andrerom force-pushed the also_symlink_extension_folder branch 2 times, most recently from 7c18f2e to f1b2798 Compare February 18, 2019 13:55
@andrerom andrerom force-pushed the also_symlink_extension_folder branch from 6e5b264 to 01f9893 Compare February 18, 2019 15:18
@andrerom andrerom changed the title [WIP] Add command "init" to creating folder structure legacy bridge usage [FEATURE] Add command "init" to configure platform install for legacy bridge usage Feb 18, 2019
@andrerom andrerom requested a review from glye February 18, 2019 15:38
@andrerom
Copy link
Copy Markdown
Contributor Author

@emodric / @vidarl Should be ready for review now, this can be expanded later with asking user to install recommended bundles / extensions as well.

Comment thread bundle/Command/LegacyConfigurationCommand.php Outdated
Comment thread bundle/Command/LegacyInitCommand.php Outdated
Comment thread bundle/Command/LegacyInitCommand.php
Comment thread bundle/Command/LegacyInitCommand.php Outdated
Comment thread bundle/Command/LegacyInitCommand.php Outdated
Comment thread INSTALL.md Outdated
glye and others added 5 commits February 19, 2019 20:34
Co-Authored-By: andrerom <andre.romcke@gmail.com>
Co-Authored-By: andrerom <andre.romcke@gmail.com>
Co-Authored-By: andrerom <andre.romcke@gmail.com>
Co-Authored-By: andrerom <andre.romcke@gmail.com>
@emodric
Copy link
Copy Markdown
Collaborator

emodric commented Feb 21, 2019

I'd like to see manual install instructions preserved in a separate file, as I don't like to rely on scripted installations 100%.

Otherwise, looks good.

@andrerom
Copy link
Copy Markdown
Contributor Author

andrerom commented Feb 26, 2019

@emodric Better?

Update: Got 👍 on slack

@andrerom andrerom merged commit 3e3fc7c into 1.5 Feb 26, 2019
@andrerom andrerom deleted the also_symlink_extension_folder branch February 26, 2019 09:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

5 participants