events.js:72 meteor up deploy - meteor

i tried everything what i found in net but nothing helped me... i try deploy app in my server on Debian 8.2, and every time after: mup deploy i got this:
Meteor Up: Production Quality Meteor Deployments
------------------------------------------------
Building Started: /Volumes/Macintosh HD/Users/myName/Google Drive/_projects/Coda/lottato_com
events.js:72
throw er; // Unhandled 'error' event
^
Error: spawn ENOENT
at errnoException (child_process.js:1011:11)
at Process.ChildProcess._handle.onexit (child_process.js:802:34)
my mup.json look lik:
{
"servers": [
{
"host": "server IP",
"username": "root",
"password": "blablabla"
}
],
"setupMongo": false,
"setupNode": true,
"nodeVersion": "0.10.36",
"enableUploadProgressBar": true,
"appName": "myAppName",
"app": "/Volumes/Macintosh HD/Users/myName/Google Drive/_projects/Coda/myAppName",
"env": {
"MONGO_URL": "//<login>:<password>#ds061464.mongolab.com:61111/myAppdb",
"ROOT_URL": "http://myApp.com"
},
"deployCheckWaitTime": 15
}
i can't handle with this issue almost 3 day! i tried deploy form server, change path, but it still didn't work and don't yet work...
and when i try to look in log, i got this:
Meteor Up: Production Quality Meteor Deployments
------------------------------------------------
[178.63.41.196] tail: cannot open ‘/var/log/upstart/lottato.log’ for reading: No such file or directory
tail: no files remaining
also u tried use mupx insted of mup, n now i got:
Invalid configuration file mup.json: There is no meteor app in the current app path.
new mup.json look like:
{
"servers": [
{
"host": "server IP",
"username": "root",
"password": "blablabla",
"env": {}
}
],
"setupMongo": false,
"appName": "appName",
"app": "~/Google Drive/_projects/Coda/appName",
"env": {
"PORT": 80,
"ROOT_URL": "http://appName.com",
"MONGO_URL": "mongodb://login:pass#ds035735.mongolab.com:35735/appName"
},
"deployCheckWaitTime": 15,
"enableUploadProgressBar": true
}
but i tried any type of path, with ~ or full path, n always the same, installation is starting only when in field path i writ:
"app": ".",

after increasing to 0.10.40 you should run 'mup setup' again followed by 'mup deploy'.
In my project I have mup.json in the project root (same level as .meteor) and
"app": "/Volumes/Macintosh HD/Users/myName/Google Drive/_projects/Coda/myAppName"
looks like
"app": ".",
Not sure if that is important.

i resolve this problem only with mupx + i moved project on server and deploy it from server to the same server.

Related

Debug Next.js App with VSCode in NX monorepo

I'm currently trying to debug a Next.js Application inside a NX monorepo.
I have enabled the Auto Attach setting in VSCode's User Settings.
When I start the Application using the serve command, I can see output in the Debug Console and also print out the current process by typing process or console.log(process) into the Debug Console.
However, I cannot set any breakpoints in the server side code, for example in getServerSideProps.
I checked Next.js Debugging Documentation for the missing pieces, and tried setting the NODE_OPTIONS='--inspect' in my Next.js Application via .env file.
Update: Seems like it's a missing feature on NX.
Got it working, thanks to the information from this Pull Request.
.vscode/launch.json
{
"version": "0.2.0",
"resolveSourceMapLocations": ["${workspaceFolder}/**", "!**/node_modules/**"],
"configurations": [
{
"name": "name-of-the-app – Server",
"type": "node",
"request": "launch",
"runtimeExecutable": "yarn",
"runtimeArgs": [
"nx",
"run",
"name-of-the-app:serve",
"-r",
"ts-node/register",
"-r",
"tsconfig-paths/register"
],
"outputCapture": "std",
"internalConsoleOptions": "openOnSessionStart",
"console": "internalConsole",
"env": {
"TS_NODE_IGNORE": "false",
"TS_NODE_PROJECT": "${workspaceFolder}/apps/name-of-the-app/tsconfig.json"
},
"cwd": "${workspaceFolder}/apps/name-of-the-app/"
}
]
}
Note: I'm using yarn. You might have to replace it with npm instead.

How do I get firebase hosting predeploy to run per target?

There is a firebase.json like this
"hosting": [
{
"target": "site-b",
"predeploy":cp ".env.site-b .env",
},
{
"target": "site-c",
"predeploy":cp ".env.site-c .env",
},
{
"target": "site-a",
"predeploy":cp ".env.site-a .env",
},
]
Deploying with a single target will work, but if multiple targets are specified, the .env will all be the same because deploy will start after all predeploys have been executed, which will not work.
I want to use Github Action FirebaseExtended/action-hosting-deploy#v0 to check the preview of multiple sites, is there a workaround?

Problem running Scrapoxy and Digital Ocean

I'm trying to run Scrapoxy with Digital Ocean. I successfully created a droplet image and configured Scrapoxy.
When I start Scrapoxy, it keeps on creating a new instance and bypassing max limit. It stops only when it reaches 10 droplets. What annoys me is that No instance found in the GUI version. Also, when I test the proxy server I get this message: "Error: No running instance found". It seems that Scrapoxy only creates droplets and can't connect to them.
I installed Scrapoxy manually. Here is my config file:
{
"commander": {
"password": ".........."
},
"instance": {
"port": 3128,
"scaling": {
"min": 1,
"max": 2
}
},
"providers": [
{
"type": "digitalocean",
"token": "5204b9654f301.............c281036bd19e283321c09680ac9c",
"region": "FRA1",
"size": "s-1vcpu-1gb",
"sshKeyName": "scrapoxy",
"imageName": "forward-proxy",
"tags": "Proxy,Amazon"
}
]
}
Did you try to put your region in lowercase in the config file
Example:
like this
"region": "fra1"
instead of
"region": "FRA1"
There are other troubleshooting steps you could take on the following github pages Issue 84 & Issue 62

mup deploy - Nothing Happens

I'm trying to deploy a meteor app to Digital Ocean. I followed the steps here, https://www.npmjs.com/package/mup and when I run 'mup deploy' from the .deploy directory nothing happens. I included my mup.js file below.
After researching this issue a common solution was to use an absolute path for the pem field but I did that and I also tried a password instead and still nothing happens. Also, if I run 'mup setup', 'mup log', 'mup start', 'mup reconfig', etc. nothing happens. Any ideas?
.deploy/mup.js
module.exports = {
servers: {
one: {
host: '100.000.00.00',
username: 'root',
//password: 'password123' <-- also tried password
pem: 'C:/Users/User/.ssh/id_rsa'
}
},
meteor: {
name: 'AppName',
path: '..',
servers: {
one: {}
},
buildOptions: {
debug: true,
},
env: {
ROOT_URL: 'http://100.000.00.00',
MONGO_URL: 'mongodb://localhost/meteor'
},
deployCheckWaitTime: 60
},
mongo: {
oplog: true,
port: 27017,
servers: {
one: {},
},
},
};
So I finally found this same question answered in a couple of places but just in case someone stumbles across this first here is the solution.
Go to the the root directory of the project then run (assuming mup was initialized in the .deploy directory):
mup setup --config .deploy/mup.js
mup deploy --config .deploy/mup.js
I'm not sure why this isn't in the documentation.

Getting a mup setup error (AWS EC2 instance)

I am trying to setup a simple Telescope Meteor app on an AWS EC2 instance and I am getting an error message when trying to run mup setup:
Here is my mup.json file:
{
// Server authentication info
"servers": [
{
"host": "ec2-54-191-197-203.us-west-2.compute.amazonaws.com",
"username": "ubuntu",
//"password": "password"
// or pem file (ssh based authentication)
//"pem": "/Users/apple/Coding/Contract Work/TelescopeApp.pem"
}
],
// Install MongoDB in the server, does not destroy local MongoDB on future setup
"setupMongo": true,
// WARNING: Node.js is required! Only skip if you already have Node.js installed on server.
"setupNode": true,
// WARNING: If nodeVersion omitted will setup 0.10.36 by default. Do not use v, only version number.
"nodeVersion": "0.10.36",
// Install PhantomJS in the server
"setupPhantom": true,
// Show a progress bar during the upload of the bundle to the server.
// Might cause an error in some rare cases if set to true, for instance in Shippable CI
"enableUploadProgressBar": true,
// Application name (No spaces)
"appName": "TelescopeApp",
// Location of app (local directory)
"app": "/Users/apple/Coding/Contract Work",
// Configure environment
"env": {
"PORT": 80,
"ROOT_URL": "http://ec2-54-191-197-203.us-west-2.compute.amazonaws.com",
"MONGO_URL" "mongodb://localhost:27017/Telescope-database"
},
// Meteor Up checks if the app comes online just after the deployment
// before mup checks that, it will wait for no. of seconds configured below
"deployCheckWaitTime": 15
}
Here is the error message:
Meteor Up: Production Quality Meteor Deployments
------------------------------------------------
/usr/local/lib/node_modules/mup/node_modules/cjson/index.js:226
throw err;
^
SyntaxError: Trailing comma in object at 10:5
}
^
File: "/Users/apple/Coding/Contract Work/Telescope/mup.json"
at SyntaxError (native)
at Object.parseJSON (/usr/local/lib/node_modules/mup/node_modules/jju/lib/parse.js:745:13)
at Object.parse (/usr/local/lib/node_modules/mup/node_modules/json-parse-helpfulerror/index.js:10:13)
at Object.exports.parse (/usr/local/lib/node_modules/mup/node_modules/cjson/index.js:90:28)
at Object.load (/usr/local/lib/node_modules/mup/node_modules/cjson/index.js:223:24)
at Object.exports.read (/usr/local/lib/node_modules/mup/lib/config.js:12:25)
at Object.<anonymous> (/usr/local/lib/node_modules/mup/bin/mup:20:23)
at Module._compile (module.js:541:32)
at Object.Module._extensions..js (module.js:550:10)
at Module.load (module.js:456:32)
What am I doing wrong?
change
"username": "ubuntu",
to
"username": "ubuntu"
You probably commented the "password: "password" line and forgot to remove the additional comma after "username": "ubuntu",.

Resources