Skip to content

Commit

Permalink
Merge pull request #75 from pkrll/dev/0.3.1
Browse files Browse the repository at this point in the history
Dev/0.3.1
  • Loading branch information
pkrll authored Jul 3, 2018
2 parents 2d481c5 + 188066b commit 9240dd1
Show file tree
Hide file tree
Showing 123 changed files with 875 additions and 14,299 deletions.
56 changes: 28 additions & 28 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,23 +1,29 @@
.PHONY: all install build start stop server devserver client devclient updater major minor patch clean
.PHONY: all install install_client install_server build start stop server devserver client devclient updater major minor patch clean

ENV = production
SERVICE = null

all: install build start

install:
ifeq ($(SERVICE), bootstrapper)
npm run install:bootstrapper
ifeq ($(SERVICE), client)
make install_client
else ifeq ($(SERVICE), server)
make install_server
else
npm run install:server
make install_client
make install_server
endif

install_client:
cd raspbot/web && npm install

install_server:
cd raspbot && npm install
cd raspbot && npm run setup

build:
ifeq ($(SERVICE), bootstrapper)
npm run build:bootstrapper
else
npm run build
endif
cd raspbot && npm run build

start:
pm2 start process.json --only Raspbot --watch
Expand All @@ -28,27 +34,21 @@ restart:
stop:
pm2 stop process.json --only Raspbot --watch 0

start_bootstrapper:
pm2 start process.json --only Bootstrapper --watch

stop_bootstrapper:
pm2 stop process.json --only Bootstrapper --watch 0

server:
ifeq ($(ENV), dev)
NODE_ENV=development npm run server
cd raspbot && NODE_ENV=development npm run dev
else
NODE_ENV=production npm run server
cd raspbot && NODE_ENV=production npm run dev
endif

devserver:
make ENV=dev server

client:
ifeq ($(ENV), dev)
npm run client
cd raspbot && npm run dev:client
else
npm run build
cd raspbot && npm run build
endif

devclient:
Expand All @@ -58,27 +58,27 @@ update:
git pull

major:
ifeq ($(SERVICE), $(filter $(SERVICE),raspbot bootstrapper))
npm run major -- --file=$(SERVICE)/package.json
ifeq ($(SERVICE), $(filter $(SERVICE),raspbot))
node .scripts/increment-version.js --version=major --skip-build --reset-minor --reset-patch --file=$(SERVICE)/package.json
else
@echo "ERROR:\tCould not increment major version."
@echo "USAGE:\tmake SERVICE=[raspbot|bootstrapper] major"
@echo "USAGE:\tmake SERVICE=[raspbot] major"
endif

minor:
ifeq ($(SERVICE), $(filter $(SERVICE),raspbot bootstrapper))
npm run minor -- --file=$(SERVICE)/package.json
ifeq ($(SERVICE), $(filter $(SERVICE),raspbot))
node .scripts/increment-version.js --version=minor --skip-build --reset-patch --file=$(SERVICE)/package.json
else
@echo "ERROR:\tCould not increment minor version."
@echo "USAGE:\tmake SERVICE=[raspbot|bootstrapper] minor"
@echo "USAGE:\tmake SERVICE=[raspbot] minor"
endif

patch:
ifeq ($(SERVICE), $(filter $(SERVICE),raspbot bootstrapper))
npm run patch -- --file=$(SERVICE)/package.json
ifeq ($(SERVICE), $(filter $(SERVICE),raspbot))
node .scripts/increment-version.js --version=patch --skip-build --file=$(SERVICE)/package.json
else
@echo "ERROR:\tCould not increment patch version."
@echo "USAGE:\tmake SERVICE=[raspbot|bootstrapper] patch"
@echo "USAGE:\tmake SERVICE=[raspbot] patch"
endif

clean:
Expand Down
26 changes: 13 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,22 +10,22 @@

<img src="docs/screenshot.png" data-canonical-src="docs/screenshot.png" align="right" width="350px"/>

``Raspbot`` is a lightweight REST API server,esigned for the **Raspberry Pi**, as well as a client web application that let's you control your device with ease.
Raspbot is a lightweight REST API server, designed for the **Raspberry Pi**, as well as a client web application that let's you control your device with ease.

Built with NodeJS & Express 4 and Vue 2 & Webpack.

**``Raspbot`` is still a work in progress**.
**Raspbot is still a work in progress**.

**Features:**

- [ ] Reboot and shutdown
- [x] Browse file system
- [x] Download files
- [ ] Upload files
- [x] Delete files
- [x] Create folders
- [x] Check temperature, CPU, memory and disk usage.
- [x] Interface to update Raspbot remotely
- [x] 📂 Browse file system
- [x] ⬇️ Download files
- [ ] ⬆️ <s>Upload files</s>
- [x] 🗑️ Delete files
- [x] 📁 Create folders
- [x] 🔌 Reboot & shutdown system
- [x] 🌡️ Check temperature, CPU, memory and disk usage.
- [x] 🎛️ Update, restart & stop Raspbot remotely

## Table of Contents

Expand All @@ -48,7 +48,7 @@ Built with NodeJS & Express 4 and Vue 2 & Webpack.
* NodeJS (__recommended version 10.4.1+__)
* Python (__developed for version 2.7.10__)
* psutil library (__developed using version 5.4.3__)
* PM2 (__required to use the Bootstrapper app__)
* PM2 (__required to update, restart or stop Raspbot remotely__)

## Installation

Expand Down Expand Up @@ -135,7 +135,7 @@ For more information on how to use PM2, check out **[the official documentation]

## Usage

By default, ``Raspbot`` runs on port 5000 and can be accessed by ``http://ip-to-your-pi:5000``.
By default, Raspbot runs on port 5000 and can be accessed by ``http://ip-to-your-pi:5000``. The default username is ``admin`` with the password ``secret``. Be sure to change this.

## Configurations

Expand Down Expand Up @@ -187,4 +187,4 @@ Restart the server.

## Author

Raspbot was created by **Ardalan Samimi**.
Raspbot was created by [**Ardalan Samimi**](https://github.com/pkrll). The robot icon was created by [FontAwesome](https://fontawesome.com/license) and is licensed under the [CC by 4.0 license](https://creativecommons.org/licenses/by/4.0/).
2 changes: 0 additions & 2 deletions bootstrapper/.gitignore

This file was deleted.

15 changes: 0 additions & 15 deletions bootstrapper/Makefile

This file was deleted.

13 changes: 0 additions & 13 deletions bootstrapper/app.js

This file was deleted.

Empty file.
22 changes: 0 additions & 22 deletions bootstrapper/app/controllers/RaspyController.js

This file was deleted.

18 changes: 0 additions & 18 deletions bootstrapper/app/controllers/SystemController.js

This file was deleted.

Empty file removed bootstrapper/app/models/.gitkeep
Empty file.
37 changes: 0 additions & 37 deletions bootstrapper/app/models/Raspy.js

This file was deleted.

34 changes: 0 additions & 34 deletions bootstrapper/app/models/System.js

This file was deleted.

15 changes: 0 additions & 15 deletions bootstrapper/app/router/index.js

This file was deleted.

55 changes: 0 additions & 55 deletions bootstrapper/app/router/socket.js

This file was deleted.

13 changes: 0 additions & 13 deletions bootstrapper/config/index.js

This file was deleted.

Loading

0 comments on commit 9240dd1

Please sign in to comment.