Cyrdup aka Cyrille Dupuydauby
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const Transaction = require('loopback-datasource-juggler'); | |
| const update = async (ids, delta) => { | |
| const result = []; | |
| const tx = await models.MyModel.beginTransaction({ isolationLevel: Transaction.READ_COMMITTED }); | |
| try { | |
| for (const id of ids) { | |
| const entity = await updateById(id, delta, { transaction: tx }); | |
| result.push(entity); | |
| } |
Instructions about how to setup a Rocket.Chat server including a HTTPS reverse proxy with docker-compose.
mongo:
image: mongo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <dom-module id="slack-login"> | |
| <style> | |
| :host { | |
| display: block; | |
| } | |
| #card { | |
| min-width: 500px; | |
| } | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var async = require('async'); | |
| Project.afterCreate = function(done) { | |
| var self = this; | |
| function createRelation(rel, next, name) { | |
| self[name].create(rel, next); | |
| }; | |
| objMapAsync(this.__cachedRelations, createRelation, done); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Configure the reverse-proxy on port 443 | |
| server { | |
| # general configs | |
| keepalive_timeout 30; | |
| listen 127.0.0.1:443 ssl; | |
| server_name api.example.com; | |
| # ssl configs | |
| ssl_certificate /path/to/api.crt; | |
| ssl_certificate_key /path/to/api.key; |