1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-09-19 16:01:34 +02:00

Working on docs

This commit is contained in:
Hillel Coren 2017-01-26 17:37:35 +02:00
parent b7b583549c
commit 4ee8ab0354
3 changed files with 37 additions and 34 deletions

View File

@ -8,18 +8,20 @@ Recurring invoices and reminder emails
Create a cron to call the ninja:send-invoices and ninja:send-reminders Artisan commands once daily.
``0 8 * * * /usr/local/bin/php /path/to/ninja/artisan ninja:send-invoices``
.. code-block:: shell
``0 8 * * * /usr/local/bin/php /path/to/ninja/artisan ninja:send-reminders``
0 8 * * * /usr/local/bin/php /path/to/ninja/artisan ninja:send-invoices
0 8 * * * /usr/local/bin/php /path/to/ninja/artisan ninja:send-reminders
Postmark bounce and open notifications
""""""""""""""""""""""""""""""""""""""
Include the following two setting in the .env file, the rest of the email settings can be commented out.
``POSTMARK_API_TOKEN=``
.. code-block:: shell
``MAIL_FROM_ADDRESS=``
POSTMARK_API_TOKEN=
MAIL_FROM_ADDRESS=
In your Postmark account settings make sure Open tracking is enabled and enter the following values under Settings > Outbound.
@ -31,18 +33,20 @@ Social/One-Click Login
Create an application in either Google, Facebook, GitHub or LinkedIn and then set the client id, secret and redirect URL in the .env file. For example:
``GOOGLE_CLIENT_ID=``
.. code-block:: shell
``GOOGLE_CLIENT_SECRET=``
``GOOGLE_OAUTH_REDIRECT=http://ninja.dev/auth/google``
GOOGLE_CLIENT_ID=
GOOGLE_CLIENT_SECRET=
GOOGLE_OAUTH_REDIRECT=http://ninja.dev/auth/google
PhantomJS
"""""""""
We use phantomjscloud.com to attach PDFs to emails sent by background processes. Check for the following line in the .env file to enable this feature or sign up to increase your daily limit.
``PHANTOMJS_CLOUD_KEY='a-demo-key-with-low-quota-per-ip-address'``
.. code-block:: shell
PHANTOMJS_CLOUD_KEY='a-demo-key-with-low-quota-per-ip-address'
You can install PhantomJS to generate the file locally, to enable it add ``PHANTOMJS_BIN_PATH=/usr/local/bin/phantomjs``. To determine the path you can run ``which phantomjs`` from the command line.
@ -67,7 +71,9 @@ Using a Proxy
If you need to set a list of trusted proxies you can add a TRUSTED_PROXIES value in the .env file. ie,
``TRUSTED_PROXIES='10.0.0.0/8,172.16.0.0/12,192.168.0.0/16'``
.. code-block:: shell
TRUSTED_PROXIES='10.0.0.0/8,172.16.0.0/12,192.168.0.0/16'
Customizations
""""""""""""""

View File

@ -3,8 +3,6 @@ Install
Thanks for taking the time to setup Invoice Ninja.
All Pro and Enterprise features from our hosted app are included in both the zip file and the GitHub repository.
.. Note:: The applications requires PHP >= 5.5.9 and MySQL.
Detailed Guides
@ -28,6 +26,8 @@ You can either download the zip file below or checkout the code from our GitHub
https://download.invoiceninja.com/ninja-v3.0.2.zip
.. Tip:: All Pro and Enterprise features from our hosted app are included in both the zip file and the GitHub repository.
- Release Notes: `github.com/invoiceninja/invoiceninja/releases <https://github.com/invoiceninja/invoiceninja/releases>`_
- Roadmap: `trello.com/b/63BbiVVe/invoice-ninja <https://trello.com/b/63BbiVVe/invoice-ninja>`_
@ -37,22 +37,22 @@ Step 2: Upload the code to your server
Copy the ZIP file to your server and then check that the storage folder has 755 permissions and is owned by the webserver user.
``cd /path/to/ninja/code``
.. code-block:: shell
``chmod -R 755 storage``
``sudo chown -R www-data:www-data storage bootstrap public/logo``
cd /path/to/ninja/code
chmod -R 755 storage
sudo chown -R www-data:www-data storage bootstrap public/logo
Step 3: Setup the database
""""""""""""""""""""""""""
Youll need to create a new database along with a user to access it. Most hosting companies provide an interface to handle this or you can run the SQL statements below.
``CREATE DATABASE ninja;``
.. code-block:: shell
``CREATE USER 'ninja'@'localhost' IDENTIFIED BY 'ninja';``
``GRANT ALL PRIVILEGES ON * . * TO 'ninja'@'localhost';``
CREATE DATABASE ninja;
CREATE USER 'ninja'@'localhost' IDENTIFIED BY 'ninja';
GRANT ALL PRIVILEGES ON * . * TO 'ninja'@'localhost';
Step 4: Configure the web server
""""""""""""""""""""""""""""""""
@ -66,11 +66,11 @@ Once you can access the site the initial setup screen will enable you to configu
Troubleshooting
^^^^^^^^^^^^^^^
- Check your webserver log (ie, ``/var/log/apache2/error.log``) and the application logs (``storage/logs/laravel-error.log``) for more details or set ``APP_DEBUG=true`` in .env
- Check your webserver log (ie, /var/log/apache2/error.log) and the application logs (storage/logs/laravel-error.log) for more details or set ``APP_DEBUG=true`` in .env
- To resolve ``[Symfony\Component\Debug\Exception\FatalErrorException] Class 'SomeClass' not found`` try running php artisan optimize
- To resolve ``file_put_contents(...): failed to open stream: Permission denied`` run ``chmod -R 777 storage`` then ``chmod -R 755 storage``
- If ``index.php`` is in the URL it likely means that mod_rewrite needs to be enabled.
- If index.php is in the URL it likely means that mod_rewrite needs to be enabled.
- Running ``composer install`` and ``composer dump-autoload`` can sometimes help with composer problems.
- If youre using a subdomain. ie, ``invoice.mycompany.com`` You will need to add ``RewriteBase /`` to ``public/.htaccess`` otherwise it may fail with ``Request exceeded the limit of 10 internal redirects due to probable configuration error.`` messages in the logs.
- If youre using a subdomain. ie, invoice.mycompany.com You will need to add ``RewriteBase /`` to ``public/.htaccess`` otherwise it may fail with ``Request exceeded the limit of 10 internal redirects due to probable configuration error.`` messages in the logs.
- Composer install error: ``Fatal error: Allowed memory size of...`` Try the following: ``php -d memory_limit=-1 /usr/local/bin/composer install``
- PHP Fatal error: ``Call to undefined method Illuminate\Support\Facades\Session::get()`` try deleting ``bootstrap/cache/services.php``
- PHP Fatal error: ``Call to undefined method Illuminate\Support\Facades\Session::get()`` try deleting bootstrap/cache/services.php

View File

@ -7,22 +7,19 @@ To update the app you just need to copy over the latest code. The app tracks the
If the auto-update fails you can manually run the update with the following commands. Once completed add ``?clear_cache=true`` to the end of the URL to clear the application cache.
``composer dump-autoload --optimize``
.. code-block:: shell
``php artisan optimize --force``
``php artisan migrate``
``php artisan db:seed --class=UpdateSeeder``
composer dump-autoload --optimize
php artisan optimize --force
php artisan migrate
php artisan db:seed --class=UpdateSeeder
Weve seen some updates fail when moving the app to a new server because the MySQL default storage engine has changed with MySQL 5.7. If you see ``SQLSTATE[HY000]: General error: 1215`` error you may be able to fix it by running this `SQL query <https://www.invoiceninja.com/forums/topic/problem-with-new-install/#post-5313>`_
.
Version 2.6
"""""""""""
Make sure the ``.env`` file includes ``APP_CIPHER=rijndael-128``
Make sure the .env file includes ``APP_CIPHER=rijndael-128``
Version 2.5.1
"""""""""""""
@ -31,7 +28,7 @@ Minimum PHP version is now 5.5.9
Version 2.0
"""""""""""
Copy ``.env.example`` to ``.env`` and set config settings
Copy .env.example to .env and set config settings
Set the app cipher to ``rijndael-256`` to support existing passwords