This manual is about setting up an automatic deploy workflow using nodejs, PM2, nginx and GitLab CI. It is tested on:
- Target server: Ubuntu 16.04 x64. This is suitable for Ubuntu 14.x.
- Windows 10 on my PC to work.
var mqtt = require('mqtt'); | |
var chid = '69432217-a8d6-4086-9d04-eea8d0ce4a55'; | |
var deviceId = 'testDevice'; | |
var devicePass = '2d70dd0e-1d57-4034-ac8a-3d01c76a9f45'; | |
var c1 = mqtt.createClient(1883, 'localhost', { | |
clientId : deviceId, | |
username : deviceId, |
{ | |
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.77 Safari/537.36", | |
"environment": { | |
"networkUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3559.0 Safari/537.36", | |
"hostUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.77 Safari/537.36", | |
"benchmarkIndex": 762.4750499001996 | |
}, | |
"lighthouseVersion": "3.2.1", | |
"fetchTime": "2018-10-26T07:23:37.412Z", | |
"requestedUrl": "https://mimtech.ir/", |
{ | |
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.77 Safari/537.36", | |
"environment": { | |
"networkUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3559.0 Safari/537.36", | |
"hostUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.77 Safari/537.36", | |
"benchmarkIndex": 814 | |
}, | |
"lighthouseVersion": "3.2.1", | |
"fetchTime": "2018-10-26T08:34:32.917Z", | |
"requestedUrl": "http://drforoosh.ir/", |
{ | |
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.77 Safari/537.36", | |
"environment": { | |
"networkUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3559.0 Safari/537.36", | |
"hostUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.77 Safari/537.36", | |
"benchmarkIndex": 508 | |
}, | |
"lighthouseVersion": "3.2.1", | |
"fetchTime": "2018-10-26T09:05:50.138Z", | |
"requestedUrl": "http://mimtech.ir/mag/", |
{ | |
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.67 Safari/537.36", | |
"environment": { | |
"networkUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3559.0 Safari/537.36", | |
"hostUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.67 Safari/537.36", | |
"benchmarkIndex": 602 | |
}, | |
"lighthouseVersion": "3.2.1", | |
"fetchTime": "2018-10-21T20:22:01.794Z", | |
"requestedUrl": "http://mazandkar.ir/", |
{ | |
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.67 Safari/537.36", | |
"environment": { | |
"networkUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3559.0 Safari/537.36", | |
"hostUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.67 Safari/537.36", | |
"benchmarkIndex": 576.8463073852296 | |
}, | |
"lighthouseVersion": "3.2.1", | |
"fetchTime": "2018-10-21T20:22:58.023Z", | |
"requestedUrl": "http://mihanvila.ir/", |
{ | |
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.67 Safari/537.36", | |
"environment": { | |
"networkUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3559.0 Safari/537.36", | |
"hostUserAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.67 Safari/537.36", | |
"benchmarkIndex": 730 | |
}, | |
"lighthouseVersion": "3.2.1", | |
"fetchTime": "2018-10-21T20:21:16.887Z", | |
"requestedUrl": "http://tameshksms.com/fa/", |
(define-module (my-module) | |
#:use-module ((guix licenses) #:prefix license:) | |
#:use-module (guix download) | |
#:use-module (guix git-download) | |
#:use-module (guix packages) | |
#:use-module (guix build-system gnu) | |
#:use-module (guix build-system cmake) | |
#:use-module (guix utils)) | |
(define-public my-custom-package |
I hereby claim:
To claim this, I am signing this object: