Johnpbloch/wordpress moved to a new configuration and WP goes missing

Hi guys, it started to do the same thing for me on my staging environment.

It has the same problem even with a newly provisioned instance.

Is it just the composer install or does it have anything to do with wordpress-install task that is not present in the server.yml (I know that probably won’t be the case, but I’m trying to think of different ipothesis).

I attempted to clear the composer cache, reinstalled manually or with the task itself but no success.

Thoughts?

I’m starting to have the same problem when running deploy now.

500 and site goes down. Manually ssh into the server cd /srv/www/example.com/current

and running

wp core download
Downloading WordPress 4.7.3 (en_US)...
Using cached file '/mnt/persist/home/deploy/.wp-cli/cache/core/wordpress-4.7.3-en_US.tar.gz'...
Success: WordPress downloaded.

Gets the site up and running.

Somewhere in the deploy WordPress doesn’t get installed as it should…

I noticed most of the deploy hooks have changed some in the latest version of Trellis. I will compare them to my current deploy-hooks to see if anything has changed.

Did you miss the solution in this thread? What you did isn’t going to prevent the issue from happening again on your next deploy, follow the steps here:

4 Likes

That’s work !! , Thank you <3

I had to clear the cache about 3 times, remove all folders and update composer but it end it worked. Thanks

Should we sticky this thread?

3 Likes

I am just trying to setup a new project using bedrock command:
composer create-project roots/bedrock project1

and I am getting this error :

Installing johnpbloch/wordpress (4.7.3): Cloning eef7c0520b from cache
    eef7c0520b1e7187cd2cd7540dc997c4c3b0340a is gone (history was rewritten?) 

then it crashes. I have tried clearing my composer cache. It still doesnt work. I am not sure if i can try a composer.json update as this is a new project and I dont have a composer.json. Help!!

I get:

`➜ site git:(master) ✗ composer remove johnpbloch/wordpress
Loading composer repositories with package information
Updating dependencies (including require-dev)

Removal failed, reverting ./composer.json to its original content.

[Composer\Downloader\TransportException]
The “https://wpackagist.org/p/providers-2017-03%24e01ff7afcea733ebe73329d5e0d2ef2e0f98737381c1e557813b1f77974d6028.json” file co
uld not be downloaded (HTTP/1.1 404 Not Found)

remove [–dev] [–no-progress] [–no-update] [–no-scripts] [–update-no-dev] [–update-with-dependencies] [–no-update-with-dependencies] [–ignore-platform-reqs] [-o|–optimize-autoloader] [-a|–classmap-authoritative] [–apcu-autoloader] [–] []…`

Seems weird. You could try composer clear-cache and try again.

I’ve run into problems with composer on stage and production.

I’ve tried clearing the cache multiple times to no avail.

I recently re-organised my package repo and added an ssl certificate. This works fine for dev.

When I try to run a deploy, it seems to be trying to load packages via the old http urls that are no longer in my updated composer.json. I’ve checked that the correct composer.json is in my remote git repo.

I can’t understand where this old composer.json is coming from or how I can get rid of it.

I’m running a version of trellis from late March and ansible 2.2.2.0.

Do I need to upgrade trellis?

This issue seems to be the same as this:

I’m going to try rebuilding from scratch.

Curious.

So I rebuilt the droplet with a fresh copy of Ubuntu 16.04.2, then re-provisioned.

Same result, the deploy fails because it is still trying to load packages from an older version of my composer.json.

I’ve found that the old urls exist in /site/vendor/composer/installed.json on my local development machine.

Does anyone know what this file is used for?

How specifically did you reinstall WP so that it forced an update of the new dependencies?

Hey Adam,
Per the thread above, follow the procedures in Post #45 above to fix this issue using a few composer steps.

1 Like

I cant deploy a brand new install and the above solutions wont solve my issue :frowning:

Can you describe what you mean by “can’t”?

A brand new install wouldn’t have this issue. Closing this thread as the solution for this thread is still the proper one :slight_smile: