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

refactor: Remove composer deps from the repository #6920

Merged
merged 1 commit into from Feb 6, 2018

Conversation

Projects
None yet
4 participants
@murrant
Member

murrant commented Jun 30, 2017

Allows users to manage installed libraries without conflicting with our git repo. And also relieves us of distributing other's code.

We can specify target versions in composer.json and exact versions will be supplied by composer.lock. This makes composer install install the exact versions we have tested with.

Testers

If you would like to test this pull request then please run:

git remote add https://github.com/murrant/librenms.git
git checkout -t murrant/composer-install
git reset --hard 394c4393a4fcf6c1ee42a6f6a07a839fe7cadc5d
./daily.sh

WARNING LibreNMS versions with known issues:

These are all fixed in 1.35

  • Break updates: 0def643 to (fix #7864)
  • Break LibreNMS until ./daily.sh is run again when distributed polling is enabled: 45b6a4c to 2e73b75
  • Break LibreNMS until ./daily.sh is run again: 3f4a35f and older

@murrant murrant changed the title from feature: remove to feature: remove composer deps from the repository, updated install docs Jun 30, 2017

@murrant murrant changed the title from feature: remove composer deps from the repository, updated install docs to refactor: remove composer deps from the repository, updated install docs Jun 30, 2017

@murrant murrant changed the title from refactor: remove composer deps from the repository, updated install docs to refactor: Remove composer deps from the repository, updated install docs Jul 1, 2017

@murrant

This comment has been minimized.

Member

murrant commented Jul 4, 2017

I still plan to go through the CentOS installs.

The validate step feels wierd, since that is the only reason to go back to the command line after install.php.

@murrant murrant referenced this pull request Jul 5, 2017

Closed

Update Installation-Ubuntu-1604-Nginx.md #6961

0 of 1 task complete
@murrant

This comment has been minimized.

Member

murrant commented Jul 6, 2017

This is ready. I have gone through all four installs and straightened out any issues.

Includes changes from #6961

@laf

This comment has been minimized.

Member

laf commented Jul 6, 2017

I'm really not sure where to go with this. It seems like a great step forward but I can't help but feel we'll be subjecting user installs to problems. As mentioned on IRC, the first one that springs to mind is those who don't have direct internet access and composer installed already, this will break for those people.

I've also had issues switching to this branch because I run composer update on my side, others may do the same when developing things.

@murrant

This comment has been minimized.

Member

murrant commented Jul 6, 2017

Second issue, I hadn't thought of, can fix that and this PR fixes that issue. However, the daily command does remove dev reqs, I'm not sure how I want to handle that yet...

As for the first issue, isn't that the same as it is now? If composer is missing, composer.phar will be automatically downloaded and used. These should respect the proxy env variable, but I haven't tested that.

@laf

This comment has been minimized.

Member

laf commented Jul 6, 2017

For the first issue: You don't need composer right now, all the code from vendor/ is included in the repo.

@murrant

This comment has been minimized.

Member

murrant commented Jul 6, 2017

Yes, but if you don't have connectivity, you can't download from the git repo. Having the dependencies inside our repo causes issues when the user runs composer. It also isn't how composer was intended to be used. It was only set up that way as a bootstrap to get to this state.

@laf

This comment has been minimized.

Member

laf commented Jul 6, 2017

You only have an issue because we don't use any proxy settings but someone might have configured git to use one. This is just one example and no right now I can't think of others but my setup isn't the same as the next person nor the next.

This could go swimmingly or it could go horribly wrong, if it's the latter then it's going to lead to people losing data on a big scale.

I can't even think of how best to test this either :(

@murrant

This comment has been minimized.

Member

murrant commented Jul 7, 2017

Testing script:

git remote add https://github.com/murrant/librenms.git
git checkout -t murrant/composer-install
git reset --hard 394c4393a4fcf6c1ee42a6f6a07a839fe7cadc5d
./daily.sh

if you do composer update before ./daily.sh it will cause the failure you asked about.

We could work around that by adding git checkout vendor before the git pull command.

@murrant

This comment has been minimized.

Member

murrant commented Jul 7, 2017

@laf git checkout vendor --quiet > /dev/null 2>&1 works to fix the issue, but it needs to be run before the git pull is done (which means we are using the existing version of daily.sh)

Can you think of any way to do that?

@laf

This comment has been minimized.

Member

laf commented Jul 8, 2017

I'm assuming vendor is a special branch?

I can't think of anyway to handle running that command before daily.sh :(

Maybe a staggered deployment of this? Add that command to daily.sh now and then this PR in a week or two with notifications everywhere we can.

What happens for people on stable branches with this, is it the same? If so that means we will have to do this over 2 months :/

@murrant

This comment has been minimized.

Member

murrant commented Jul 8, 2017

Vendor is ./vendor/ the directory.
I think maybe stagger it before and after a release too.

It will remove all development dependencies from the vendor directory. FYI, to avoid being annoyed you might do what I have done for now and install phpunit, parallel-lint, and php_codesniffer in another directory and put the bin dir in PATH.

@murrant

This comment has been minimized.

Member

murrant commented Jul 8, 2017

Just think after this change you can have anything you want in your vendor dir and it won't mess up updates :)

@murrant murrant added this to the 1.31 milestone Jul 28, 2017

@murrant murrant referenced this pull request Aug 9, 2017

Merged

Docs: Allow host renames with selinux enforcing #7136

1 of 1 task complete
@laf

This comment has been minimized.

Member

laf commented Aug 11, 2017

@murrant What about people who run updates manually?

@laf

This comment has been minimized.

Member

laf commented Aug 11, 2017

I've checked this out to leave running overnight.

Still concerned that this will not go well for people with unusual setups.

What happens if a user has git configured to use a proxy so git pull works but then it can't get any composer dependencies?

What about users who just run git pull and don't run composer afterwards?

I'm sure a number of other scenarios exist.

@murrant

This comment has been minimized.

Member

murrant commented Aug 14, 2017

What happens if a user has git configured to use a proxy so git pull works but then it can't get any composer dependencies?

If they have configured git directly to use a proxy with git config --global http.proxy composer will fail to get the updates and they will receive an error in the webui, command line, and validate.php. If they have set the environment variable HTTP_PROXY (or http_proxy), it will work properly.

What about users who just run git pull and don't run composer afterwards?

They will receive an error in the webui and command line, and validate.php.

Here is the error message: Missing dependencies, run: composer install --no-dev

@murrant

This comment has been minimized.

Member

murrant commented Aug 14, 2017

Hmm, I could check if the proxy is set in git and pull that in.

@laf

This comment has been minimized.

Member

laf commented Aug 14, 2017

So this is still the same for me as it's always been. I'm concerned this will break installs with no way for us to force a fix. This means a loss of data until people realise which in turn means a loss in confidence.

@murrant

This comment has been minimized.

Member

murrant commented Aug 14, 2017

@laf are you not convinced this is where we need to go?

@laf

This comment has been minimized.

Member

laf commented Aug 14, 2017

@murrant mostly although longer term I don't think polling and discovery should be php based.

The issue I have is the unknown of how many users might be left with broken installs from this - it could be non.

What about installing a new project via the composer install this would run but without removing everything else and we find some way of alerting users if that doesn't exist?

@murrant

This comment has been minimized.

Member

murrant commented Aug 14, 2017

@laf We could do some sort of test and block updates with a warning in the webui. Might even be able to use the same code for the php version changes later.

@laf

This comment has been minimized.

Member

laf commented Aug 15, 2017

@laf We could do some sort of test and block updates with a warning in the webui. Might even be able to use the same code for the php version changes later.

That would be brilliant if we can, I know that still won't be 100% but it's better than causing users issues.

@murrant murrant modified the milestones: 1.32, 1.31 Aug 25, 2017

@murrant murrant removed this from the 1.32 milestone Sep 26, 2017

@laf

This comment has been minimized.

Member

laf commented Nov 15, 2017

Just gone back to test this again. Probably me getting confused and another PR might bring composer support but:

-bash-4.2$ git reset --hard 394c4393a4fcf6c1ee42a6f6a07a839fe7cadc5d
HEAD is now at 394c4393a newdevice: Add Calix AXOS/E5-16F Detection (#6926)
-bash-4.2$ rm composer.
composer.json  composer.phar
-bash-4.2$ rm composer.phar -f
-bash-4.2$ ./daily.sh
Updating to latest codebase                        OK
Updated from 394c4393a4fcf6c1ee42a6f6a07a839fe7cadc5d to 80f38366b5a56403af91b9cabb4e521dbb7785ab OK
Composer not available, please manually install composer.
Updating SQL-Schema                                FAIL
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 42
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 42
Updating submodules                                OK
Cleaning up DB                                     FAIL
Composer not available, please manually install composer.
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 42
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 42
Error: Missing dependencies, run: composer install --no-dev
@murrant

This comment has been minimized.

Member

murrant commented Nov 16, 2017

Yeah, I probably need to revisit this to make sure merges didn't mess anything up.

@murrant

This comment has been minimized.

Member

murrant commented Nov 23, 2017

@laf doh, I hardcoded the sha. Now we get the sha as described on the composer site.

https://getcomposer.org/doc/faqs/how-to-install-composer-programmatically.md

@laf

This comment has been minimized.

Member

laf commented Nov 23, 2017

Ok so next issue is that this breaks everything until you re-run daily.sh which means anyone on auto updates will be broken for 24 hours or until they manually re-run daily:

-bash-4.2$ git reset --hard 394c4393a4fcf6c1ee42a6f6a07a839fe7cadc5d
HEAD is now at 394c4393a newdevice: Add Calix AXOS/E5-16F Detection (#6926)
-bash-4.2$ ./daily.sh
Updating to latest codebase                        OK
Updated from 394c4393a4fcf6c1ee42a6f6a07a839fe7cadc5d to 5c1f477fbdc57d2ecf5cd051d0081d00102b0ee6 OK
-bash-4.2$ ./poller.php -h localhost -v -m os
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44

If I re-run daily, things continue to function as normal.

@murrant

This comment has been minimized.

Member

murrant commented Nov 24, 2017

@laf hmm, looks like you have distributed poller enabled blocking post-update tasks. After #7735 is merged, I can fix that.

@laf

This comment has been minimized.

Member

laf commented Dec 2, 2017

@murrant #7735 merged. Just a reminder :)

@laf

This comment has been minimized.

Member

laf commented Jan 6, 2018

@murrant
Doesn't look like composer still gets installed:

-bash-4.2$ ./daily.sh
Composer not available, please manually install composer.
Checking PHP version                               FAIL
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Composer not available, please manually install composer.
Updating Composer packages                         OK
Reverting update, check the output of composer diagnose FAIL
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
fatal: ambiguous argument 'unset': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Updating SQL-Schema                                FAIL
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Updating submodules                                OK
Cleaning up DB                                     FAIL
Composer not available, please manually install composer.
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Fetching notifications                             FAIL
Composer not available, please manually install composer.
Error: Missing dependencies, run: composer install --no-dev

PHP Warning:  require(/opt/librenms/vendor/autoload.php): failed to open stream: No such file or directory in /opt/librenms/includes/init.php on line 44
PHP Fatal error:  require(): Failed opening required '/opt/librenms/vendor/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /opt/librenms/includes/init.php on line 44
Caching PeeringDB data                             OK
@laf

This comment has been minimized.

Member

laf commented Jan 6, 2018

It's checking an old SHA value for composer-setup.php which is why it's failing.

@murrant

This comment has been minimized.

Member

murrant commented Jan 7, 2018

Hmm, I thought I fixed that, maybe I didn't push it.

@laf

This comment has been minimized.

Member

laf commented Jan 8, 2018

Seems better now:

-bash-4.2$ git reset --hard 394c4393a4fcf6c1ee42a6f6a07a839fe7cadc5d
HEAD is now at 394c4393a newdevice: Add Calix AXOS/E5-16F Detection (#6926)
-bash-4.2$ ./daily.sh
Updating to latest codebase                        OK
Updated from 394c4393a4fcf6c1ee42a6f6a07a839fe7cadc5d to eac128aca8bdbc2ccfcd6e043d1f889c11d0417f OK
Updating SQL-Schema                                OK
Updating submodules                                OK
Cleaning up DB                                     OK
Fetching notifications                             OK
Caching PeeringDB data                             OK
-bash-4.2$ ./daily.sh
Checking PHP version                               OK
Updating to latest codebase                        OK
Updating SQL-Schema                                OK
Updating submodules                                OK
Cleaning up DB                                     OK
Fetching notifications                             OK
Caching PeeringDB data                             OK
@laf

This comment has been minimized.

Member

laf commented Jan 8, 2018

Just the travis fail now which is due to the phpunit version?

@murrant

This comment has been minimized.

Member

murrant commented Jan 8, 2018

@laf I'm holding off on this until after #8042

There are significant daily.sh changes there. I've designed them with this in mind.

@laf

This comment has been minimized.

Member

laf commented Jan 11, 2018

#8042 is now all merged in. Let me know if you need anything from me on this PR?

@laf laf removed this from To Do in PHP Min Version 5.6.4 Jan 14, 2018

@murrant

This comment has been minimized.

Member

murrant commented Jan 29, 2018

@laf new method:

I deleted vendor from the repo.
Users:

  1. git pull (vendor goes away)
  2. composer pre-install-hook: if vendor/autoload.php is missing, checkout out vendor files from known good sha
  3. run composer install
@laf

This comment has been minimized.

Member

laf commented Jan 31, 2018

Looks good to me.

Removed composer.phar it got re-installed
Removed vendor/autoload.php and composer install was run
Removed vendor/ and composer install was run.

I am seeing complaints of .lock file not matching but all seems to run ok:

-bash-4.2$  git reset --hard 394c4393a4fcf6c1ee42a6f6a07a839fe7cadc5d
HEAD is now at 394c4393a newdevice: Add Calix AXOS/E5-16F Detection (#6926)
-bash-4.2$ ./daily.sh
Updating to latest codebase                        OK
Updated from 394c4393a4fcf6c1ee42a6f6a07a839fe7cadc5d to 81c111d0e46d7c34ec99f579b485946552dfed24 OK
> LibreNMS\ComposerHelper::preInstall
git checkout 92e1048940638a738c8c12aa27337871bfc3a06f -- /opt/librenms/vendor
git reset HEAD /opt/librenms/vendor
Loading composer repositories with package information
Installing dependencies from lock file
Warning: The lock file is not up to date with the latest changes in composer.json. You may be getting outdated dependencies. Run update to update them.
Package operations: 15 installs, 0 updates, 0 removals
  - Installing amenadiel/jpgraph (3.6.6): Loading from cache
  - Installing dapphp/radius (2.5.1): Loading from cache
  - Installing easybook/geshi (v1.0.8.18): Loading from cache
  - Installing ezyang/htmlpurifier (v4.9.3): Loading from cache
  - Installing slim/slim (2.6.3): Loading from cache
  - Installing palanik/corsslim (v1.1.0): Loading from cache
  - Installing pear/console_color2 (0.1.2): Loading from cache
  - Installing pear/console_table (v1.3.0): Loading from cache
  - Installing php-amqplib/php-amqplib (v2.0.2): Loading from cache
  - Installing phpmailer/phpmailer (v5.2.26): Loading from cache
  - Installing ramsey/array_column (1.1.3): Loading from cache
  - Installing rmccue/requests (v1.7.0): Loading from cache
  - Installing symfony/yaml (v2.8.33): Loading from cache
  - Installing tecnickcom/tcpdf (6.2.13): Loading from cache
  - Installing xjtuwangke/passwordhash (dev-master a7bcd97): Cloning a7bcd9705a from cache
Generating optimized autoload files
Updating Composer packages                         OK
Updated from unset to                              OK
Updating SQL-Schema                                OK
Updating submodules                                OK
Cleaning up DB                                     OK
Fetching notifications                             OK
Caching PeeringDB data                             OK
-bash-4.2$ ./daily.sh
Checking PHP version                               OK
Updating to latest codebase                        OK
Updating Composer packages                         OK
Updating SQL-Schema                                OK
Updating submodules                                OK
Cleaning up DB                                     OK
Fetching notifications                             OK
Caching PeeringDB data                             OK
-bash-4.2$ rm vendor/autoload.php
-bash-4.2$ ./daily.sh
> LibreNMS\ComposerHelper::preInstall
git checkout 92e1048940638a738c8c12aa27337871bfc3a06f -- /opt/librenms/vendor
git reset HEAD /opt/librenms/vendor
Loading composer repositories with package information
Installing dependencies from lock file
Warning: The lock file is not up to date with the latest changes in composer.json. You may be getting outdated dependencies. Run update to update them.
Nothing to install or update
Generating optimized autoload files
Checking PHP version                               OK
Updating to latest codebase                        OK
Updating Composer packages                         OK
Updating SQL-Schema                                OK
Updating submodules                                OK
Cleaning up DB                                     OK
Fetching notifications                             OK
Caching PeeringDB data                             OK
-bash-4.2$ rm vendor/ -Rf
-bash-4.2$ ./daily.sh
> LibreNMS\ComposerHelper::preInstall
git checkout 92e1048940638a738c8c12aa27337871bfc3a06f -- /opt/librenms/vendor
git reset HEAD /opt/librenms/vendor
Loading composer repositories with package information
Installing dependencies from lock file
Warning: The lock file is not up to date with the latest changes in composer.json. You may be getting outdated dependencies. Run update to update them.
Package operations: 15 installs, 0 updates, 0 removals
  - Installing amenadiel/jpgraph (3.6.6): Loading from cache
  - Installing dapphp/radius (2.5.1): Loading from cache
  - Installing easybook/geshi (v1.0.8.18): Loading from cache
  - Installing ezyang/htmlpurifier (v4.9.3): Loading from cache
  - Installing slim/slim (2.6.3): Loading from cache
  - Installing palanik/corsslim (v1.1.0): Loading from cache
  - Installing pear/console_color2 (0.1.2): Loading from cache
  - Installing pear/console_table (v1.3.0): Loading from cache
  - Installing php-amqplib/php-amqplib (v2.0.2): Loading from cache
  - Installing phpmailer/phpmailer (v5.2.26): Loading from cache
  - Installing ramsey/array_column (1.1.3): Loading from cache
  - Installing rmccue/requests (v1.7.0): Loading from cache
  - Installing symfony/yaml (v2.8.33): Loading from cache
  - Installing tecnickcom/tcpdf (6.2.13): Loading from cache
  - Installing xjtuwangke/passwordhash (dev-master a7bcd97): Cloning a7bcd9705a from cache
Generating optimized autoload files
Checking PHP version                               OK
Updating to latest codebase                        OK
Updating Composer packages                         OK
Updating SQL-Schema                                OK
Updating submodules                                OK
Cleaning up DB                                     OK
Fetching notifications                             OK
Caching PeeringDB data                             OK
-bash-4.2$ ./daily.sh
Checking PHP version                               OK
Updating to latest codebase                        OK
Updating Composer packages                         OK
Updating SQL-Schema                                OK
Updating submodules                                OK
Cleaning up DB                                     OK
Fetching notifications                             OK
Caching PeeringDB data                             OK
-bash-4.2$ rm composer.phar
-bash-4.2$ ./daily.sh
Checking PHP version                               OK
Updating to latest codebase                        OK
Updating Composer packages                        ll  OK
Updating SQL-Schema                                OK
Updating submodules                                OK
Cleaning up DB                                     OK
Fetching notifications                             OK
Caching PeeringDB data                             OK
-bash-4.2$ ls composer.phar
composer.phar
@murrant

This comment has been minimized.

Member

murrant commented Feb 1, 2018

yeah, the warning is because we modified our composer.json and did not run update afterwards. But, it is just a warning.

Remove dependencies from the repository, update install docs
After vendor is un-indexed restore the contents so things keep working.
@scrutinizer-notifier

This comment has been minimized.

scrutinizer-notifier commented Feb 3, 2018

The inspection completed: 699 Issues, 30 Patches

@murrant murrant merged commit 9b9fb12 into librenms:master Feb 6, 2018

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
license/cla Contributor License Agreement is signed.
Details

@murrant murrant deleted the murrant:composer-install branch Feb 6, 2018

@laf laf removed the Blocker 🚫 label Feb 6, 2018

@sthen

This comment has been minimized.

Contributor

sthen commented Feb 27, 2018

If someone doesn't have composer installed already, this downloads it from a non-https site, only checked against a signature from another non-https site (and this is run automatically from a cronjob if the vendor directory isn't present). Is that what's intended?

@laf laf referenced this pull request Feb 27, 2018

Closed

Update composer_wrapper to use http links #8305

1 of 1 task complete
@laf

This comment has been minimized.

Member

laf commented Feb 27, 2018

Unsure if it's intended as such but: #8305

inetAnt added a commit to criteo-forks/librenms that referenced this pull request Mar 19, 2018

Remove dependencies from the repository, update install docs (librenm…
…s#6920)

After vendor is un-indexed restore the contents so things keep working.
@lock

This comment has been minimized.

lock bot commented May 16, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed.

@lock lock bot locked as resolved and limited conversation to collaborators May 16, 2018

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.