Skip to content
Grav 2.0 is officially stable. Read the announcement →
Archive

Troubles with deploying Grav updates - Am I doing it wrong?

Started by Muut Archive 11 years ago · 10 replies · 484 views
11 years ago

I have a consistent problem with upgrading and updating Grav on my local server and then deploying it to my remote server. I get a broken site on the remote, even though the local is fine, every time.

Here are my steps:

  • Commit (Git) all local changes
  • Do bin/gpm selfupgrade
  • Do bin/gpm update
  • Do bin/grav composer
  • Do bin/grav clear-cache
  • Commit those changes
  • Run phploy to upload the changes recorded by Git to the remote server via FTP
  • Do bin/grav clear-cache on the remote server

That always give this this error when attempting to load the remote site:

PHP
Fatal error: Class 'CSSmin' not found in /home/bobrocke/public_html/materialize.bobrockefeller.com/system/src/G rav/Common/Assets.php on line 561

Fatal error: Uncaught exception 'RuntimeException' with message 'Could not find resource 'whoops.css' in any resource paths.(searched: /home/bobrocke/public_html/materialize.bobrockefeller.com/system/asset s, /home/bobrocke/public_html/materialize.bobrockefeller.com/vendor/filp/ whoops/src/Whoops/Handler/../Resources)' in /home/bobrocke/public_html/ materialize.bobrockefeller.com/vendor/filp/ whoops/src/Whoops/Handler/PrettyPageHandler.php:500 Stack trace: #0 /home/bobrocke/public_html/materialize.bobrockefeller.com/vendor/filp/ whoops/src/Whoops/Handler/PrettyPageHandler.php(126): Whoops\Handler\PrettyPageHandler->getResource('whoops.css') #1 /home/bobrocke/public_html/materialize.bobrockefeller.com/vendor/filp/ whoops/src/Whoops/Run.php(256): Whoops\Handler\PrettyPageHandler->handle(Object(Whoops\Exception\Error Exception)) #2 /home/bobrocke/public_html/materialize.bobrockefeller.com/vendor/filp/ whoops/src/Whoops/Run.php(327): Whoops\Run->handleException(Object(Whoops\Exception\ErrorException)) #3 /home/bobrocke/public_html/ma in /home/bobrocke/public_html/materialize.bobrockefeller.com/vendor/filp/ whoops/src/Whoops/Handler/PrettyPageHandler.php on line 500

The a bin/grav composer on the remote server fixes things.

What am I doing wrong?

11 years ago

The vendor/ folder, on the server, is correctly filled with the dependencies like in localhost?

11 years ago

Apparently not, but I don't know why it shouldn't be.

11 years ago

I think they're not stored in the Git server due to .gitignore, try commenting the vendor lines in it

11 years ago

My .gitignore doesn't include the vendor folder. On purpose. It does include composer.lock; should it not?

11 years ago

It does in the current version, although in the next Grav release, composer.lock is removed from .gitignore because we're going to use composer install rather than composer update to ensure versions in vendor are consistent.

11 years ago

I'm not using Grav's default .gitignore.

11 years ago

Maybe I just need to do as rhukster suggested: just upload \user and update Grav on the remote server directly.

11 years ago

This approach has been solid for us, and has never been an issue. Also gives you the opportunity to thoroughly test out a grav release local before deciding to update the remote, independent of content usually (unless some new content or plugin requires the update).

I don't even think when its just a content update though. I just make the edits, test it local, commit, and push.. I usually don't even bother checking the remote site because it's so reliable, i just know it's going to look the same.

Suggested topics

Topic Participants Replies Views Activity
Archive · by Deleted User, 9 years ago
0 1334 9 years ago
Archive · by Muut Archive, 9 years ago
2 924 9 years ago
Archive · by Muut Archive, 9 years ago
2 4055 9 years ago
Archive · by Muut Archive, 9 years ago
1 2938 9 years ago
Archive · by Muut Archive, 9 years ago
3 1111 9 years ago