/xampp/lang.php not found - linux

I am new to linux(ubuntu). I installed XAMPP server in my system.. but after installing when i am using browser it shows the following error:
Not Found
The requested URL /xampp/lang.php was not found on this server.
Apache/2.2.22 (Ubuntu) Server at localhost Port 80

If you are using linux, you don't need xampp, linux has native packages for PHP development, called lamp (linux, apache, MySQL, PHP). In fact almost all web servers around the world that runs PHP are linux servers.
There are some easy steps that you can quickly install lamp unsing ubuntu's terminal.
sudo apt-get install lamp-server^
Note The caret (^) at the end of the command is important.
This will install the latest PHP, MySQL and Apache2 that is it in the Ubuntu repository (depending on your ubuntu version)
You can also install each component individually, here you can find the complete steps
Install LAMP Server on Ubuntu with a 1-line Command
It is also a good idea for development environment to setup a workspace directory in your home folder to hold your projects and than making virtualhost files in your /etc/apache2/sites-available folder (you need sudo privileges).
More about virtual hosts on Apache virtual hosts
This approach helps a lot with permissions of read/writes on your project files.
Best regards,

Related

How to upload laravel project on remote server

I'm trying to install new laravel project via ssh connection on remote server based on ubuntu. I've faced following problem:
This project requires php 7.2 zip extension I guess. But I've already had php 7.2.
Can someone help me with this?
P.S. I've tried every command like sudo apt-get install php7*- and etc...

how to host angular and node js project on the shared hosting (cpanel or plesk)?

I have two different shared hosting on GoDaddy server (cPanel and Plesk odin), I want to host my NodeJS project there.
You CAN do this.
Most tutorials have you downloading node + npm through the command line... and since you cannot use sudo in terminal on a shared GoDaddy server you have to install nvm to install npm and node.
But really, you only need a single file from the Node.js package to get a server running. It is much easier to download the package, and manually add the one file to cPanel.
Follow this tutorial for the most simple method of running a Node.js server on GoDaddy hosting.
You can't host Node project on cpanel. You will need a node server for that. Cpanel does not come with node installed, neither it could be Installed. You can check with aws or blueocean for that.

React: How to publish page on server using React-starter-kit

So, I created a page using repo from:
https://github.com/kriasoft/react-starter-kit
I have my own global ftp server. And now I would like to publish my project on server.
What is the best way to do it. Should I copy all files to ftp server and just exec command 'npm start'? Or maybe I should deploy it?
I'm new in web deployment and not sure how it works.
Thanks for any tips.
It may be a little more complicated than just ftping your project up. Here are the instructions I use to setup a server at digitalocean.
sudo apt-get update
sudo apt-get install npm
sudo apt-get install git
sudo apt-get install ufw
sudo apt-get install build-essential libssl-dev
curl https://raw.githubusercontent.com/creationix/nvm/v0.20.0/install.sh | bash
nvm install stable //may require new ssh session before this
ufw default deny incoming
ufw default allow outgoing
ufw allow ssh
ufw allow 80/tcp
ufw allow out to any port 53
ufw enable
sudo npm install -g forever
sudo npm install -g node-gyp
cd /var
mkdir www
cd www
git clone https://github.com/calitek/palminfo --recursive
npm install
npm ls -depth 0
export PORT=80
node js/server.js
test using ip / when good exit then
forever start js/server.js
set dns
The server will need to support you adding node.js. Then you need to preferably use github to clone the project. You will want to do the npm install on the server to be sure you are using the correct modules. Its a little complicated the first time out, just keep good notes for the next time.
This is a big topic to cover, whatever your linux distribution is, you probably will always need 2 servers - a proxy server, and an app server.
I'd recommend you wrap your compiled sites with a simple Node.js server like Express or Hapi. Then configure nginx to properly route all the requests to the application. Checkout some detailed guides from DigitalOcean
CentOS: https://www.digitalocean.com/community/tutorials/how-to-set-up-a-node-js-application-for-production-on-centos-7
Ubuntu: https://www.digitalocean.com/community/tutorials/how-to-set-up-a-node-js-application-for-production-on-ubuntu-14-04
Minor steps might be slightly different but you get the idea
One approach is to build the app on the server, but you will need something like Heroku which you already decided to go with.
But an alternative to that is to do a paradigm shift. You're app is basicaly just some html, css and javascript, which is compiled and servered to the public. You could compile that yourself with npm run build and then just copy the compiled files to your hosting server which can use what ever server it wants: apache httpd, nginx, etc. This is also cheaper cause you only need basic hosting, not some complex nodejs compiling server.
I created a starter kit http://redux-minimal.js.org/ which helps you create rich real-world apps with the minimum amount of packages and very light configuration setup. If you look at the folder structure you can see that the app uses the index.html from the public folder, and then the css and js file are compiled directly in the public folder. Which makes it easier to just copy the public folder to what ever server you want.

Apache HTTP Server offline installation

Is is possible to use Apache web server with out installing latest rpm for Apache HTTPD using rpm Uvh httpd<version>.<arch>.rpm or yum install httpd , like we can do for tomcat on Linux machines? Because i don't have root access to run rpm or yum
We can achieve this for tomcat just by copy the tomcat directory toany desired location and run startup.sh , it would start the server running on default port 8080 and could be accessed using hostname:/8080.
But when I looked for such ready to use dump on Apache site i didn't find it for Linux.
However for windows i have such feature available on apachelounge.com... Is offline installation of Apache HTTP Server possible on Linux?
On windows we can download the binaries from http://www.apachelounge.com/download/
and just run the executable httpd.exe which would get the work done in couple of minutes.

How to install Cloud9 Local IDE on Chromebook

i'm using a Chromebook HP 11 in developer mode.
I installed Ubuntu v12.04 Unity on it, with Crouton.
On Ubuntu, i installed Nodejs (v0.6.12), npm (v1.1.4) and build-essential as it's said here : https://c9.io/site/blog/2012/06/cloud9ide-new-features/
But i don't know how to install the Cloud9 Local IDE, which i downloaded here :
http://static.c9.io/c9local/prod/c9local-latest.tgz
Can someone tell me how i should do it ?
In advance, Thanks.
you can do this two ways...
if you plan to install it directly to chromeOS you will need to put your machine into developer mode and have writeable rootfs. There's a tutorial here. NOTE- it's my understanding that this option voids a warranty, although perhaps that's true also with option #2 below
The other option is to install Ubuntu with Crouton as it's own OS and then install node/npm.
I opted for the later and have the cloud9 service running locally with Apache and MySql. Ubuntu will share the Downloads folder, so you can set up a folder there to manage all your local virtual hosts, etc.

Resources