Run InvoiceNinja - Invoice and Payment Manager - in Docker

Channel:
Subscribers:
14,500
Published on ● Video Link: https://www.youtube.com/watch?v=KcinTq69lag



Category:
Tutorial
Duration: 2:18
433 views
20


#InvoiceNinja #Invoice #Docker

Full steps can be found at https://i12bretro.github.io/tutorials/0820.html

--------------------------------------------------------------------
What is InvoiceNinja?
--------------------------------------------------------------------
[InvoiceNinja is a] powerful suite of features to invoice clients, facilitate payment, track-time & tasks, expenses, and more. - https://www.invoiceninja.com/invoicing-features/
 
--------------------------------------------------------------------
Installing Docker
--------------------------------------------------------------------
   01. Log into the Linux based device
   02. Run the following commands in the terminal
         # install prerequisites
         sudo apt install apt-transport-https ca-certificates curl software-properties-common gnupg-agent -y
         # add docker gpg key
         curl -fsSL https://download.docker.com/linux/$(awk -F'=' '/^ID=/{ print $NF }' /etc/os-release)/gpg | sudo apt-key add -
         # add docker software repository
         sudo add-apt-repository "deb [arch=$(dpkg --print-architecture)] https://download.docker.com/linux/$(awk -F'=' '/^ID=/{ print $NF }' /etc/os-release) $(lsb_release -cs) stable"
         # install docker
         sudo apt install docker-ce docker-compose containerd.io -y
         # enable and start docker service
         sudo systemctl enable docker && sudo systemctl start docker
         # add the current user to the docker group
         sudo usermod -aG docker $USER
         # reauthenticate for the new group membership to take effect
         su - $USER
 
--------------------------------------------------------------------
Running the InvoiceNinja Container
--------------------------------------------------------------------
   01. Now that Docker is installed, run the following commands to setup the InvoiceNinja Docker container and run it
         # create working directories
         mkdir ~/docker/invoiceninja/{public,storage} -p && mkdir ~/docker/mariadb -p && mkdir ~/docker/nginx -p
         # download the invoiceninja nginx config
         wget -O ~/docker/nginx/invoiceninja.conf https://raw.githubusercontent.com/invoiceninja/dockerfiles/master/config/nginx/in-vhost.conf
         # update the config file with the invoiceninja container name
         sed -i 's/fastcgi_pass app:9000;/fastcgi_pass invoiceninja:9000;/g' ~/docker/nginx/invoiceninja.conf && sed -i 's/listen 80 default_server;/listen 80;/g' ~/docker/nginx/invoiceninja.conf
         # set ownership on the working directories
         sudo chown "$USER":"$USER" ~/docker -R
         # allow the container to write to files/ and settings.php
         sudo chmod a+rwx -R ~/docker/invoiceninja
         # run the mariadb docker container
         docker run -d --name mariadb -e MYSQL_ROOT_PASSWORD=r00tp@$$ -e MYSQL_USER=invoiceninja_rw -e MYSQL_PASSWORD='!nv0ic3Ninj@!' -e MYSQL_DATABASE=invoiceninja -v ~/docker/mariadb:/var/lib/mysql -p 3306:3006 --restart=unless-stopped mariadb:latest
         # generate application key
         docker run --rm -it invoiceninja/invoiceninja php artisan key:generate --show
         # run the invoiceninja container
         # change the IN_USER_EMAIL and IN_PASSWORD variables to setup the default user
         # update the APP_KEY variable with the key generated earlier
         docker run -d --name=invoiceninja --link mariadb -p 8080:80 -v ~/docker/invoiceninja/public:/var/www/app/public -v ~/docker/invoiceninja/storage:/var/www/app/storage -e IN_USER_EMAIL='i12bretro@i12bretro.local' -e IN_PASSWORD='SomethingSecure!' -e REQUIRE_HTTPS=false -e APP_ENV='production' -e APP_DEBUG=0 -e APP_URL='http://ubuntuserver.local:8080' -e APP_KEY='≪%key generated earlier%≫' -e APP_CIPHER='AES-256-CBC' -e DB_TYPE='mysql' -e DB_STRICT='false' -e DB_HOST='mariadb' -e DB_DATABASE='invoiceninja' -e DB_USERNAME='invoiceninja_rw' -e DB_PASSWORD='!nv0ic3Ninj@!' --restart=unless-stopped invoiceninja/invoiceninja
         # run the nginx container
         docker run --name nginx --link invoiceninja -p 8081:80 -v ~/docker/invoiceninja/public:/var/www/app/public:ro -v ~/docker/nginx:/etc/nginx/conf.d:ro -d nginx
   02. Open a web browser and navigate to http://DNSorIP:8081
   03. Login with the Email and Password setup in the InvoiceNinja container variables ≫ Click Login with email
   04. On the Welcome dialog, enter a company name and select the Light or Dark theme ≫ Click Save
   05. Welcome to InvoiceNinja
 
Documentation:  https://hub.docker.com/r/invoiceninja/invoiceninja
 


### Connect with me and others ###
★ Discord: https://discord.com/invite/EzenvmSHW8
★ Reddit: https://reddit.com/r/i12bretro
★ Twitter: https://twitter.com/i12bretro







Tags:
Browser Based
Container
Containerization
Docker
Docker How To
Docker Installation Tutorial
Docker Made Easy
Docker Simplified
Docker Tutorial
Expense Tracker
Home Lab
Home Lab Ideas
Homelab
How To
Install Guide
Invoice
Invoice Ninja
InvoiceNinja
Invoicing Software
Linux
Payment Manager
Self-Hosted
Tutorial
Ubuntu
Web Based
Web Based Tools
i12bretro