I am using Lumen (of Laravel) as my backend and using vagrant. I am want to install and use FFmpeg but I got confused how to install it.
Do I need to install it on my localhost or add it to Lumen? or both?
I found this page but I got lost which commands to run.
Update: I installed this repo on Github and run it in vagrant. I think this installed the latest version on my local server, but what should I do next? How can I install and use FFMpeg with Lumen in php?
Go to your Homestead folder, run vagrant ssh. This will get you into your vagrant machine's terminal. Run command sudo apt-get install ffmpeg there and acknowledge the questions you get asked. (Additional libraries for PHP integration might be required.) FFMpeg will be ready to use.
Related
I have a Laravel application and docker setup for local development using docker-compose. My source code for the application is kept in BitBucket and now I would like to deploy the application to a Linode instance and serve it from the docker system. How this can be done ? As of now I have a LAMPP image running in Linode and I push my source code to the corresponding path when deployment is triggered. Now I would like to use the same docker image in the server instead of the LAMPP server I am using. How this can be done ? Or this is the correct method of doing it ?
It will be helpful if someone can point out a tutorial or guide for doing this ?
If you are locked on staying with linode, I would try one of these options:
Linode docker machine driver - note that this is a non official docker machine driver.
Linode containers guide - using Kubernetes, which I usually try to avoid for my small-scale apps.
If you are NOT locked on staying with linode, and you wish to avoid the complexities of Kubernetes, I can tell you I have had success with running a docker machine on Digital Ocean - this solution (as most other docker-machine solutions) makes deployment as easy as running it locally.
List of docker machine drivers
Digital Ocean docker machine guide
As for how to get your code PHP code to the container, here is an example Dockerfile I have been using for one of my PHP dockerized apps:
FROM php:7-apache
# Packages
RUN apt-get -y update && apt-get -y install git zip
RUN a2enmod rewrite && docker-php-ext-install sockets
# App
COPY . .
# Composer
COPY private/composer.phar /usr/local/bin/composer
RUN chmod +x /usr/local/bin/composer
RUN [[ ! -f composer.json ]] || composer install --ansi --no-interaction
You can adjust it to your needs.
I am currently updating our docker image in Azure.From this image appsvcorg/alpine-php-mysql:0.3 to this leonzhang77/alpine-php-mysql:0.31.
After pasting and save it on container,restart app, when I browse my site (linux.rapidvisa.com , Wordpress 4.9.7,PHP7) that error appeared.MySQL also cannot connect to var/run/mysqld/mysqld.sock.
I tried to fix it. I can see on my phpinfo.php that MySQL/MySQLi is not there or not running.
I am new in this Docker and Azure environment although I managed to enter into SSH and do some tweaking but no luck.
I tried to type sudo apt-get install blah..but command not found.Whenever I typed major commands always -ash: command not found. Can somebody advise me what to do?
i dont know what the exact problem is with your docker construct but your second one is the alpine distribution.
in alpine linux there is an other package manager system.
you have to use apk.
like: apk update or apk add htop
guys I have a shared hosting and I can't use SSH or call shells with php (shell_exec),for security reasons, I can't upgrade my server for money problems...But i need to install Composer, and work with an SDK for finish my project?Is there any way to install/use composer without SSH? I have read about install Composer offline, and then upload the contents on the server, but i don't think that this work...
Thanks for read! Hope that you all'll have a nice day!
As You Said You Want to Install Composer Without SSH then
In that case you Have to install it in your local system than after you can easily upload it using FTPand its Works if your host is supported !!
Steps For Shared Hosting Using FTP::
First Download Php Shell From Here: http://phpshell.sourceforge.net/
In PHPShell's config.php Add User & alias:
php = "php -d suhosin.executor.include.whitelist=phar"
Login to PHPShell & Type: curl -sS https://getcomposer.org/installer | php
After Successfully installed, Just Run Composer: php composer.phar
I am currently learning PHP Laravel. I am in the process of setting up valet. However, I encountered a problem. Whenever I type (filename).dev, it shows the XAMPP main page instead of the Laravel initial project page. Can someone explain why this is happening?
The original answer can be found here.
Remove valet completely (some reason valet uninstall does nothing) so to get the latest version (v1.1.3 at the time)
Stop Apache: apachectl stop
Update Valet: composer global require laravel/valet
Install Valet: valet install
Restart Valet: valet restart
With some others, it might be a good option to try and simply turn-off/stop your locally running Apache, as this as others might find is only the issue that fixes it.
I faced the same issue as I was running Xampp and Valet at the same time on my Windows Machine, try turning off the xampp/apache and run the page again.
Steps to install Valet on Windows..
Install composer from https://getcomposer.org/download/
Then run composer global require cretueusebiu/valet-windows
Then run: "valet install"
Open your Laravel project directory in cmd (administrator mode)
Then run: "valet park"
Then run: "valet link"
Then run: "valet secure" (if you want your website to be secured by TLS)
In the control panel/network and sharing center choose the active connection and in its properties enter 127.0.0.1 in TCP/IPv4 IPv4 settings
In the control panel/network and sharing center choose the active connection and in its properties enter ::1 in TCP/IPv6 IPv6 settings
Then run: "valet start"
Enter the "projectname" followed by ".test" in the browser.
For example: if your project name is demolaravel, then run demolaravel.test in the browser
I was trying to run the gulp command in the windows command promptafter installing node_modules in my laravel installation but it came back with this error in my windows command prompt :-
'gulp' is not recognized as an internal or external command,
operable program or batch file.
I was trying to use Lavarel Elixir and as in the Laracast videos I was trying to get the gulp command working on my command prompt but it shows
I installed node_modules using the below command
npm install --no-bin-links
it installed all the files
I am using Netbeans as my IDE and it is showing an error in the node_modules folder also , so I am unsure as to how to get this fixed and Working
My Work Environment is
Apache through MAMP
OS :- Windows 10
IDE :- Netbeans
Thanking you in anticipation
In order to be able to run gulp you need to install the gulp command line interface globally like so: npm install -g gulp-cli. Afterwards you need to add a gulpfile.js where you would configure your builds/tasks. For more information check out the official "Getting started" guide and the docs on gulp: https://github.com/gulpjs/gulp/blob/master/docs/getting-started.md