Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add method to programatically to run DB migration + schema update #1907

Closed
Firefishy opened this issue Aug 8, 2017 · 2 comments
Closed

Add method to programatically to run DB migration + schema update #1907

Firefishy opened this issue Aug 8, 2017 · 2 comments
Labels
enhancement improvements to existing features

Comments

@Firefishy
Copy link

Firefishy commented Aug 8, 2017

Description

Currently there seems to be no way to programatically or automatically run a DB migration / schema updates.

Steps to reproduce

  1. Install and configure Craft v2.6.2978
  2. http://example.com/ works. HTTP 200.
  3. Replace files with Craft v2.6.2988
  4. http://example.com/ fails with HTTP 503.
  5. Run: yiic migrations up
  6. http://example.com/ still fails with HTTP 503. All migrations have run, but DB craft_info.schemaVersion is mismatched.
  7. http://example.com/admin/ click Update.
  8. http://example.com/ works. HTTP 200.

After Step 5 (or using another method) the site should load HTTP 200.
In reality step 3 is by replacing the app container with a new container with the new version.

Additional info

  • Craft version: 2.6.2988
  • PHP version: 7.1
  • Database driver & version: N/A
  • Plugins & versions: N/A
@brandonkelly brandonkelly added the enhancement improvements to existing features label Aug 15, 2017
@brandonkelly
Copy link
Member

Agree that it is weird that running migrate up from the command line will not update the app/plugin schema version once it's done.

@hiasl
Copy link
Contributor

hiasl commented Nov 15, 2017

+1 for Craft3: Please provide a command for this last step, otherwise it's hard to do it via Jenkins

brandonkelly added a commit that referenced this issue Dec 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement improvements to existing features
Projects
None yet
Development

No branches or pull requests

3 participants