Skip to content
Snippets Groups Projects
Commit 69a1d1f6 authored by Alice Poggioli's avatar Alice Poggioli
Browse files

add build existing app

parent 10574955
No related branches found
No related tags found
No related merge requests found
Pipeline #5480 passed with stage
in 36 seconds
How to build a SIB application from sources
#########################################
Requirements
============
npm 6.7.0
Configure the app
==================
Get the code of your app (for the example the SIB App):
.. code-block:: bash
git clone https://git.happy-dev.fr/startinblox/applications/sib-app.git /tmp/sib_app
cd /tmp/sib_app
Create JON file and configure the client to contact the servers:
.. code-block:: json
{
{
"xmpp": "https://jabber.happy-dev.fr/http-bind/",
"authority": "http://api.batman.happy-dev.fr/",
"clientName": "Sib App",
"authorityName": "batman",
"publicDirectory": false,
"endpoints": {
"circles": "https://api.batman.happy-dev.fr/circles/",
"users": "https://api.batman.happy-dev.fr/users/"
},
"analytics": []
}
The parameters are:
.. list-table::
:stub-columns: 1
* - xmpp
- authority
- authorityName
- clientName
- endpoints
* - the BOSH access of your Prosody's server
- the primary OpenID authority url, for sib-auth
- the primary OpenID authority name, for sib-auth
- your client name, for sib-auth
- api points to the server to contact for each capability
In this example we are contacting the same server (batman.happy-dev.fr) for all our application capabilities. Because we installed the server with this configuration we know it supports all capabilities we need. But we could point each capability to different servers as long as they support it.
If you use a local development server, you should use http://localhost:8000/ instead.
Build the client app
==================
Create your application bundle:
.. code-block:: bash
npm run build
The application bundle is in the dist folder, ready to be deployed everywhere as a static file.
You can serve your application locally (assuming you already have a SIB server setup) to check its behavior:
.. code-block:: bash
npm run watch
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment