You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Customer signup with email id and password(CommonDb.users id:1 email: [email protected] )
POST /api//users
constmainDomain='tenantapp.com';constlinodeIp='120.120.120.120'// either we can use this function of we can keep *.tenantapp.com -> 120.120.120.120// linode centos server with ip 120.120.120.120constcreateDNS=(subdomain)=>{rp({url: `https://api.digitalocean.com/api/domains/${mainDomain}/A`,method: POST',body: { subdomain,ip: linodeIp}})}exportasyncfunctioncreate(req,res,next){constuser=awaitCommonDb.User.create({email: req.body.email});// id:1constdomain=req.body.email.split('@')[1];constsubdomain=domain.split('.')[0];constproject='nps_feedback';constconnectionString=awaitMySQLApi.createDb(`${subdomain}_${project}`);constclient=awaitCommonDb.Client.create({user_id: user.id,name: subdomain, connectionString });awaitSequelizeApi.migrateDb(connectionString);awaitSequelizeApi.seedDb(connectionString);// all subdomains pointing to one machine as wildcard dns entryuser.update({client_id: client.id});res.json({message: 'Signup successful, Provisioning done from http://${subdomain}.${mainDomain}'})}
domain: flipkart.tenantapp.com1.dbinfo=DBCreationScript2.dbId=saveDbInfoToCommonDbClientsTable(dbInfo)3.
The text was updated successfully, but these errors were encountered:
Customer signup with email id and password(CommonDb.users id:1 email: [email protected] )
POST /api//users
The text was updated successfully, but these errors were encountered: