2019-04-29 12:46:13 +00:00
# SiB App
2018-11-07 18:05:32 +00:00
2019-04-29 12:46:13 +00:00
SiB App is the magic tool that allows the Happy Dev network to thrive in a decentralized way.
2018-09-28 19:24:25 +00:00
2019-04-29 12:46:13 +00:00
## Getting Started
2018-11-14 12:50:38 +00:00
2019-04-29 12:46:13 +00:00
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.
2018-11-14 12:50:38 +00:00
2019-04-29 12:46:13 +00:00
### Prerequisites
2018-11-14 12:50:38 +00:00
2019-04-29 12:46:13 +00:00
To install SiB App, you'll need to have:
2018-11-14 12:50:38 +00:00
2019-04-29 12:46:13 +00:00
- Python3 & Pip
- NodeJS & NPM
- A Prosody Server
- (Optional) A SMTP Server
2018-11-14 12:50:38 +00:00
2019-04-29 12:46:13 +00:00
### Installing
2018-11-14 12:50:38 +00:00
2019-10-27 13:57:27 +00:00
[Install a server and a client application ](https://git.happy-dev.fr/startinblox/devops/doc/wikis/deploy_a_sib_application )
2018-11-14 12:50:38 +00:00
2019-10-27 13:57:27 +00:00
Or build the docker images and run it:
2019-04-29 12:46:13 +00:00
```
2019-10-27 13:57:27 +00:00
$ docker build -t sibapp docker/
$ docker run --rm -p 127.0.0.1:8000:8000 -it sibapp
2019-04-29 12:46:13 +00:00
```
2018-11-14 12:50:38 +00:00
2019-10-27 13:57:27 +00:00
## FIXME
2018-11-14 12:50:38 +00:00
2019-10-27 13:57:27 +00:00
Create a Client ID for Prosody & Client
2018-09-28 19:24:25 +00:00
2019-04-29 12:46:13 +00:00
- Go to `localhost:8000/admin/`
- Login with previously created account.
- If needed you can create another admin account with `./manage.py createsuperadmin`
- Add a `Clients` on `OpenID Connect Provider` section
- Name it as you wish
- `Client type` : `Public`
- `Response types` : `id_token token (Implicit Flow)`
- `Redirect URIs` :
```
http://localhost:3000
http://127.0.0.1:3000
http://0.0.0.0:3000
http://localhost:8000
https://myserver.com
```
- Keep the `6-digits` newly create `Client ID` somewhere
2019-10-27 13:57:27 +00:00
Configure `config.json` :
2019-04-29 12:46:13 +00:00
On the newly created `./src/config.json` change the `dev` configuration like this:
```
"dev": {
"sdn": "http://api.myserver.com", # Or localhost:8000
"cdn": "https://cdn.happy-dev.fr",
"xmpp": "https://prosody.myserver.com/http-bind/",
"client_id": "000000" # < - Here goes your previously created Client ID
},
```
## Built With
* [Sib-Core ](https://git.happy-dev.fr/startinblox/framework/sib-core/ ) - An awesome new framework!
### Architecture
Some general schema of the existing StartinBlox applications architecture can be found [here ](https://docs.google.com/presentation/d/1iCRGaJpFvZjhjIUnpsn6lRTJJ31ES6n94BNkJygzUwM/edit?usp=sharing ).
<!-- -
## Contributing
We may add a `CONTRIBUTING.md`
## License
We may add a `LICENSE.md`
## Acknowledgments
* Maybe some thanks too
* Inspiration
* etc
2019-10-27 13:57:27 +00:00
--->