Firstly, I have deployed a Laravel project from Windows to server by copying everything in my Laravel folder and upload them to server, after configuring .htaccess, it ran successfully.
And then, I added a new package named "dompdf" by using command line, and it ran successfully in my Windows local. But I don't know how to deploy this package to linux server. I have tried but it failed.
Do I have to install composer on the Linux server?
Do I need to re-install again on the Linux server?
I have asked some people. But they have always said that "you have to install composer on Linux server". But I realize that I do not need to install anything at all. I just uploaded and override file app/config/app.php and some folders in the vendor folder that are new or changed after I added the package "dompdf".
Sorry about my English. If something is wrong, please correct it for me.
You need to install the package using Composer:
1) Require this package in your composer.json:
'barryvdh/laravel-dompdf": "0.4.*'
2) do a composer update from your terminal: php composer.phar update
3) After updating composer, add the ServiceProvider to the providers array in app/config/app.php
'Barryvdh\DomPDF\ServiceProvider',
4) You can optionally use the facade for shorter code. Add this to your facades:
'PDF' => 'Barryvdh\DomPDF\Facade',
Related
My hoster allows to install node-js applications by using cPanel. I tried to install etherpad-lite, but once visiting the URL of the app, the app isn't working, just this notice is thrown out "It works! NodeJS 11.15.0".
Here's a screenshot of the cPanel:
As you can see, there's no package.json file in the directory. Maybe here's the issue? I just cloned the git repo as indicated in the installation guide, which results in the following file structure on my server:
I am aware of this very similar question, but since it was posted in 2015 and still has no suitable answers, I issued a new and more specific question with more information.
I hope someone can point me into the right direction.
Application start up file should be "src/bin/run.sh" (from root folder). This will install all the dependencies and start the server.
i have try to install facturascripts in a windows server, server it´s working fine with many websites in php with laravel, wordpress, .... but when i try to put facturascripts in a domain it doesn´t work, i have translate .htaccess to a web.config file, but still not working.
i think the problem is with routing system, so i execute composer install and npm install to be sure everything is ok, but still nothing. bootstrap css and js files gives error 404, but the route chrome gives me is correct.
someone has facturascript 2020 working in IIS??
Check that the NPM dependencies have actually been downloaded in the node_modules folder. I recently saw a case that npm install failed on a Windows machine.
Here is the FacturaScripts official website with documentation to answer these questions.
i followed the official meteor instructions for adding package support to 3rd party libraries (source: https://github.com/MeteorCommunity/discussions/issues/14).
When i test the meteor integration with meteor add i keep getting an error:
add: You're not in a Meteor project directory.
I can't figure out whats missing??
EDIT: To be more clear: I ve forked phaser.io to my local devmachine and added a meteor directory to the root of the phaser library. The meteor directory contains export.js, package.js and test.js.
You need to initialise a meteor project directory with:
meteor create myappname
cd myappname
meteor add mymeteoruser:mypackagename
This is assuming you've published your package as per the linked instructions in your question.
You can only add a package if you have already created a meteor app for it to go into (on a really basic level this creates a .meteor folder containing all the necessary bits and pieces to keep track of which packages you have installed)
I have just installed laravel 4 using composer in my linux os. While it was downloading and installing all the packages it also gave me a lot of suggestions. It asked me to install
symfony/config
symfony/yaml
symfony/dependemcy-injection
symfony/class-loader
symfony/validator
doctrine/dbal
symfony/expression-language
doctrine/annotations
ext-phpiredis
ext-curl
ext-gmp
paer-pear/PHP_Compat
ext-intl
graylog2/gelf-php
raven/raven
doctrine/couchdb
ruflin/elastica
ext-amqp
ext-mongo
aws/aws-sdk-php
rollbar/rollbar
Should I install these things. And if I have to then how would I install them? Thanks in advance. :D
You don't have to install them for Laravel to function any differently. You should only install them if you explicitly plan on using them. The install directions are usually found on the project's github page.
All of those packages can be found on http://www.packagist.com where you will easily be able to find them, see install directions, usage, etc...
To install them, usually you'd just add the appropriate line, usually found in the documentation, to your composer.json file, run composer update and they should automatically be made available to your project.
You got suggestions for both PHP library packages (PHP code) and PHP extensions (C code).
You should only install the PHP libraries if you know you want to use them. The suggestion feature of Composer allows any developer of a package to let Composer announce on update that there might be more software that enhances the library, but is entirely optional. The description next to the package name might have details on why the package could be installed. For example, a library for FTP and HTTP access might want to use existing FTP or HTTP clients, and will announce both as suggestions. If you decide you don't need FTP access, you only require the HTTP client to be used.
You cannot install PHP extensions via Composer. Installing them usually requires some kind of administrator access to the server, and depends on which OS is installed and whether or not it allows to install these extensions as a regular software package, or needs to have the PECL install toolchain available. If a PHP library suggests a PHP extension, then this extension also is completely optional, and you probably will know that if you need that feature (like access to MongoDB), you need the PHP extension as a prerequisite, but are likely to already have it installed (which would skip this suggestion from the list because it is fulfilled).
I'd like to use the "socket.io-servicebus" module to my node.js application.
But I encountered that a problem.
After installing the "socket.io-servicebus", cloud_package.cspkg file was not created by "Publish-AzureServiceProject" command.
I'm using "Windows Azure PowerShell" on Windows7 64bit edition.
Here is the procedure.
New-AzureServiceProject test1
Add-AzureNodeWebRole www
cd www
npm install socket.io-servicebus
Publish-AzureServiceProject -ServiceName xxx ...
[ cloud_package.cspkg will not created ]
By the way "Start-AzureEmulator -Launch" will be succeeded and we can test own application.
Please give me some advices. thank you.
It looks like the issue here is due to a known path length limitation. Azure has a limitation on paths in the package being more than 255 chars and in this case bringing in socket.io WITH all of it's dependencies is hitting that path.
There are several possible work arounds here.
A. - Zip up node modules and extract on the server.
Basically you zip up your modules and publish the module zip within the package. Then you can use an Azure startup task (in your cscfg) on the server to unzip the files.
Publish-AzureServicePackage will grab anything in the project, so in this case you just have a little script that you run before publishing which creates the node_modules archive and deletes node_modules.
I am planning to do a blog post on this, but it is actually relatively easy to do.
B. - Download node modules dynamically
You can download modules in the cloud. This can also be done with a startup task as is shown here.
If you look in that post you will see how you can author a startup task if you decide to do the archive route.
Feel free to ping me with any questions.