{"id":27877,"date":"2018-08-30T03:39:30","date_gmt":"2018-08-30T08:39:30","guid":{"rendered":"https:\/\/www.rosehosting.com\/blog\/?p=27877"},"modified":"2022-06-03T03:34:42","modified_gmt":"2022-06-03T08:34:42","slug":"how-to-install-invoice-ninja-on-debian-9","status":"publish","type":"post","link":"https:\/\/www.rosehosting.com\/blog\/how-to-install-invoice-ninja-on-debian-9\/","title":{"rendered":"How to Install Invoice Ninja on Debian 9"},"content":{"rendered":"
<\/p>\n
In this tutorial, we will show you how to install Invoice Ninja on Debian 9. Invoice Ninja is an open-source software application for invoicing and billing customers. It is built using PHP, on top of the Laravel framework. Some of the features include recurring invoices, creating tasks and projects, invoice designs, more than 40 payment options, and partial payments.<\/p>\n
Looking to get some fully managed hosting for InvoiceNinja account? We offer complete migration, installation, optimization, and customization – 100% free of charge! Check out our premium affordable Linux VPS hosting<\/a> packages and switch to a more secure, more efficient server with 24\/7\/265 amazing customer support today.<\/p>\n <\/p>\n This guide should work on other Linux VPS<\/a> systems as well but was tested and written for Debian 9 VPS<\/a>. If you want to install Invoice on CentOS 7, follow this tutorial.<\/a><\/p>\n Log in to your VPS via SSH as a sudo user:<\/p>\n Once you are logged in, issue the following commands to make sure all installed packages are up to date:<\/p>\n To install Nginx, MariaDB PHP 7 and all ty nessesary PHP modules on your Debian server run the following command:<\/p>\n When the MariaDB installation is complete, run the following command to secure your MariaDB installation:<\/p>\n Login to the MariaDB console with the root account:<\/p>\n Create a MariaDB database, user and grant permissions to the user using the following command:<\/p>\n Do not forget to replace ‘strongpassword’ with an actual strong password.<\/p>\n <\/a><\/p>\n We can either download the archive file from the Download the latest stable version of the Invoice Ninja zip archive in the Once the download is completed extract the archive in the Change the ownership to the Open your favorite text editor and create a new Nginx server block for the Invoice Ninja:<\/p>\n Activate the server block by creating a symbolic link with the following command:<\/p>\n Test the Nginx configuration and if there are no errors restart the nginx service\u00a0 using the following commands:<\/p>\n Open From here you can finish the setup by entering the following information:<\/p>\n Application Settings<\/strong><\/p>\n Database Connection<\/strong><\/p>\n Email Settings<\/strong><\/p>\n Enter your email settings. You can use either you VPS SMTP or any supported third party SMTP provider.<\/p>\n User Details<\/strong><\/p>\n This is your\u00a0Invoice Ninja administrator account. Enter your first name, last name, email address and password. That\u2019s it. You have successfully installed Invoice Ninja on Debian 9. For more information about how to manage your Invoice Ninja installation, please refer to the official Invoice Ninja documentation<\/a>.<\/p>\n Of course, you don\u2019t have to install Invoice Ninja on Debian 9, if you use one of our Linux VPS Hosting<\/a> services, in which case you can simply ask our expert system administrators to install Invoice Ninja on Debian 9 for you, using the LEMP stack or any other web hosting stack of your choice. They are available 24\u00d77 and will take care of your request immediately.<\/p>\n PS.<\/strong><\/span>\u00a0If you liked this post, on how to install Invoice Ninja on Debian 9, please share it with your friends on the social networks using the buttons below or simply leave a comment in the comments section. Thanks.<\/p>\n\n\n <\/p>\n","protected":false},"excerpt":{"rendered":" In this tutorial, we will show you how to install Invoice Ninja on Debian 9. Invoice Ninja is an open-source … <\/p>\nStep 1: Update your Debian server:<\/h3>\n
ssh userame@IP_Addressinv<\/pre>\n
sudo apt-get update\nsudo apt-get upgrade<\/pre>\n
Step 2: Install Nginx, MariaDB and PHP 7<\/h3>\n
sudo apt-get install nginx php-fpm mysql-server php-cli php-common php-curl php-gd php-mysql php-xml php-mcrypt\u00a0php-mbstring<\/pre>\n
sudo mysql_secure_installation<\/pre>\n
Step 3: Create a MariaDB database for Invoice Ninja<\/h3>\n
mysql -u root -p<\/pre>\n
MariaDB [(none)]> CREATE DATABASE ninja;\nMariaDB [(none)]> GRANT ALL PRIVILEGES ON ninja.* TO 'ninja'@'localhost' IDENTIFIED BY 'strongpassword';\nMariaDB [(none)]> FLUSH PRIVILEGES;\nMariaDB [(none)]> \\q<\/pre>\n
Step 4: Download Invoice Ninja<\/h3>\n
download.invoiceninja.com<\/code>or check out the code from the GitHub Invoice Ninja repository. If you clone the GitHub repository you will need to use Composer to install the Invoice Ninja PHP dependencies while the archive file includes all required third-party PHP packages. In this post, we will install Invoice Ninja using the zip archive.<\/p>\n
\/tmp<\/code> directory on your server with:<\/p>\n
wget https:\/\/download.invoiceninja.com\/ -O \/tmp\/invoice-ninja.zip<\/pre>\n
\/var\/www\/html\/<\/code> directory:<\/p>\n
sudo unzip \/tmp\/invoice-ninja.zip -d \/var\/www\/html\/<\/pre>\n
www-data<\/code> user with the following command:<\/p>\n
sudo chown -R www-data: \/var\/www\/html\/ninja<\/pre>\n
Step 5: Configure Nginx to serve Invoice Ninja<\/h3>\n
sudo nano \/etc\/nginx\/sites-available\/your_ninja_domain.com.conf<\/pre>\n
server {\n listen 80 default_server;\n server_name your_ninja_domain.com www.your_ninja_domain.com;\n\n root \/var\/www\/html\/ninja\/public;\n\n index index.php;\n\n charset utf-8;\n\n location \/ {\n try_files $uri $uri\/ \/index.php?$query_string;\n }\n\n location = \/favicon.ico { access_log off; log_not_found off; }\n location = \/robots.txt { access_log off; log_not_found off; }\n\n access_log \/var\/log\/nginx\/your_ninja_domain.com.access.log;\n error_log \/var\/log\/nginx\/your_ninja_domain.com.error.log;\n\n sendfile off;\n\n location ~ \\.php$ {\n fastcgi_split_path_info ^(.+\\.php)(\/.+)$;\n fastcgi_pass unix:\/var\/run\/php\/php7.0-fpm.sock;\n fastcgi_index index.php;\n include fastcgi_params;\n fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;\n fastcgi_intercept_errors off;\n fastcgi_buffer_size 16k;\n fastcgi_buffers 4 16k;\n }\n\n location ~ \/\\.ht {\n deny all;\n }\n}\n<\/pre>\n
sudo ln -s \/etc\/nginx\/sites-available\/your_ninja_domain.com.conf \/etc\/nginx\/sites-enabled\/your_ninja_domain.com.conf \n<\/pre>\n
sudo nginx -t\nsudo service nginx restart\n<\/pre>\n
<\/a><\/h3>\n
Step 6: Install Invoice Ninja<\/h3>\n
http:\/\/your_ninja_domain.com\/<\/code> in your favorite web browser and you will be redirected to the Invoice Ninja setup page.<\/p>\n
\n
\n
Finally select the I agree to the Terms of Service and Privacy Policy and click on the Submit button to finish the installation.<\/p>\n
\n