Server Deployment - CriGoT/auth0-update-email GitHub Wiki
This document will explain you how to run the application in your own server
Before starting make sure to have completed the [creation of the application Auth0](Prepare your Auth0 tenant) and that you have all the information required to configure the application
-
Get the latest version of the code to your machine
git clone https://github.com/CriGoT/auth0-update-email.git -
Set the configuration values in the file
config.jsonconst config = { AUTH0_DOMAIN: '.auth0.com', // Use the value Domain copied from the application settings page AUTH0_CLIENT_ID:'', // Use the value Client ID copied from the application > settings page AUTH0_CLIENT_SECRET: '', // Use the value Client Secret copied from the application > settings page AUTH0_CONNECTION: '', // Use the Database connection name copied from the application > connections page AUTH0_MANAGEMENT_TOKEN: '', // Use the token obtained from the Token Manager } export default config;
-
Initialize the solution
npm install -
Create the bundled version of the application. This command will consolidate all resources and apply the required transformations to the application
npm run bundle-standalone -
You can now run the file
build/bundle.jsin any nodejs installation you have.
To run the application on your own machine execute
npm start
To run in a different server copy the build\bundle.js file and execute
node bundle.js
To succesfully run the application there is on additional step. You must register the callback in the application registration in Auth0. To do so you must know DNS name of the server o servers that will run the application. Let's consider that we want to run the application for development locally (http://localhost:3000/) and in a server call updatemail (https://updatemail/).
The steps required to register the callback can be found [here](Register Callback)