Question

How do I go about uploading a site to a port on the IP?

Posted October 9, 2016 1.8k views
Apache

I have a Laravel API I want to upload to a DigitalOcean droplet. I want to upload it on to a port on the IP. I am not sure if I am using the correct jargon when I say “port on the IP”

Basically, I want my API to connect when I type in xxx.xxx.xxx.xxx:port where port is the port number.

I have made a .conf file in /etc/apache2/sites-available. The code is below:

Listen xxx.xxx.xxxx.xxx:8037
    <VirtualHost xxx.xxx.xxxx.xxx:8037>
    ServerName www.servername.com
    DocumentRoot "/var/www/html/hotelguide/public"
    <Directory /var/www/html/hotelguide/public>
        AllowOverride All
        Order allow,deny
        Require all granted
        Allow from all
    </Directory>
    </VirtualHost>

I used 8037 as a random port as some were already in use (its not my droplet, its a droplet I share with other people)

I have not changed any other file, nor added any other file either

Thank you

1 comment
  • …I am a little unclear: are you asking how to upload content to your website folder, or are you asking how to properly configure your Laravel Website so that it can run your API and allow remote connections?

    Have you tried to connect yet using the site config you describe above? Have you enabled that site config yet?

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

1 answer

Use SSH(SCP) or FTP to put your codebase in “/var/www/html/hotelguide/public” … and thats it …

Submit an Answer