How to deploy a laravel-websockets server on Heroku free plan? - php

I just implemented web-sockets on my laravel php app using the laravel-websockets library. I wanted to know how to deploy it to heroku as it requires me to run another server with command "php artisan websockets:serve".
I have already deployed the app on heroku, I just need help with deploying the websocket server to Heroku.

It's not currently possible to have a websockets server running
alongside a PHP app on Heroku.
As stated in https://help.heroku.com/8R7OO0ZV/can-i-run-a-websockets-server-using-php-on-heroku which was the first result of a search of "heroku websocket php" on google.

Related

How to deploy web application by using Gitlab CI/CD on Microsoft Azure

I'm trying to deploy PHP based web application on Microsoft Azure by using Gitlab CI/CD.
Previously I used to deploy my web application on Heroku without touching anything on Heroku just by using Gitlab CI/CD, I wanted to do the same thing with Microsoft Azure.
Thank You.

How to run Larvel's php artisan commands on Google App Engine

I have my staging site for a Laravel app hosted on a Google App Engine instance. The production site is hosted on Compute Engine and isn't a managed server so I am not as familiar with the set up on GAE - I wanted to try it out in order to eventually move our production site onto a managed server.
I'm having an issue where I can't figure out how to run php artisan commands on staging! I managed to use the google sdk and the cloud sql proxy in order to access the staging database, and I assumed I could use some kind of gcloud command to run the artisan command, like something like gcloud --compute="php artisan migrate" but I can't figure out the best way to do it.
I also have tried using GCP's in-app terminal to ssh into the instance, but it seems like I have no access to the actual project files within that ssh so I can't run the artisan commands.
Does anyone know best practices for running a migration on this type of server?
I'm also using an app.yaml file to build the instance, so I was thinking maybe I should figure out how to put the command there, but I'm not sure if that's the right move as the only information I have in that file is the env info and server resources info.
Please help! thank you :)
One way of running migrations to your laravel project that is hosted on Google App Engine would be to connect your local environment project to the project's Google Cloud SQL. From there you can just run the migrations from your local environment.
Like #TMK said, connect through the SQL proxy. It's simple.
Create an SQL instance using the instructions found here
Follow the instructions here
with that done, you can run your migration command right from your bash terminal

How can I create a local installation of a php app?

Basically I want to know if it's possible to create a local installation of a PHP application with his own database and with the .exe bringing embedded XAMP with Apache?
So the client just executes the .exe and click next..next..next and the app has his icon and ready to use without further configuration.
You can do setup your PHP app in the Docker container. And to configure the docker app on the client machine he can use docker desktop application for mac/windows.
Once the docker desktop will be installed then he can run the app using just one docker command.
docker-compose up -d
Your app will be up and running on any one machine. But if you're new with docker then set up your app in docker could be a little challenging.
Ref: https://docker-curriculum.com/

Azure Web App PHP 7.1 websocket does not work

I'm trying to deploy PHP code with Websocket in in a Azure Web App environment.
It works fine on a Virtual server but it does not run as a Web App.
I find some older articles that this might not work.
I like to avoid useing Virtual servers, so any insight on how to solve this?
The solution was to deploy a Docker container image - this was the only way we could find that solved the problem.

Ratchet web socket is not working on aws ubuntu 14.04 ec2 instance

I have to implement Ratchet Web Socket server on AWS Ubuntu LTS 14.04 EC2 instance so I can create chat application using php.
But my application is not connecting to Ratchet server. My php application is working fine locally well so there are no code issue. My question is :
is firewall blocking my php application to connect with AWS server?
My findings:
Ratchet Service is running fine on AWS. Here is screenshot of
Ratchet Service status.
I am not using AWB load balencer.
I also set security group from AWS Console.
Here is screen shot of security group setting:
Security Group Setting
So how can I implement Ratchet with AWS EC2 Ubuntu with php application?
So where I missed any configuration?
Thanks in Advance.

Categories