Vapid deploy on windows not working


I am trying to deploy my vapid website to Vapid Hosting by running:
vapid deploy .
It is stuck on
==> Deploying your website…
(tried to let it run for half an hour without any result).
I am on windows 10 with latest of vapid (0.2.2).

Anyone facing the same issue?

@thibaudlacan That doesn’t sound good. Deployment should kick off and complete within a few seconds. I have a couple of questions:

  1. Does your site contain any large files (e.g. over 5MB), or a high number of files?
  2. Can you ping or curl

Thanks @scott for your reply.

  1. No, only small files, it’s a tiny one page website, so no high number of files either

  2. I’m getting time out when ping:

    Pinging [] with 32 bytes of data:
    Request timed out.
    Request timed out.
    Request timed out.
    Request timed out.

    Ping statistics for
    Packets: Sent = 4, Received = 0, Lost = 4 (100% loss),

Sorry, I just realized that you won’t be able to ping the server. Can you try curl

Redirecting to <a href=""></a>.

I have the same issue - on a mac and I can’t get it to deploy.

Any ideas?

Figured it out. Needed to shut down the production enviroment before deploying, haha.

What do you mean by that?
I’m still stuck at:

Shut down the local server (ctrl + c) I presume (or just close terminal). Reboot again, and then first you do is “vapid deploy projectname

@thibaudlacan Sorry, I missed your earlier reply re: curl.

Well, it’s good that your computer is at least seeing—that rules out network issues. A few more questions:

  • What version of Node are you running?
  • Are you CSS/JS rendering correctly when you run your local development server (i.e., vapid start)?
  • The first time you ran vapid deploy did you see a message saying “Please enter your Vapid credentials…”?

@scott no problem :slight_smile:

  • Node: v10.9.0
  • It’s rendering perfectly fine, admin is working and all with vapid start
  • Yes it prompt me to enter my credentials the first time

This leads me to another question, on the meantime i could deploy through a friend’s Mac where she is able to deploy to her beta hosting, but she would need to logout and login with my account to deploy. Is there a command to logout?

Let’s try a few things before having you bug your friend. Re: logout, right now there isn’t a command, but you can delete the Vapid entry in ~/.netrc.

First, let’s see if it can successfully create a tmp directory:

cd /your/project/directory

Then run the following in the Node prompt:

const tmp = require('tmp');
const { resolve } = require('path');
const { writeFileSync } = require('fs');
const { execSync } = require('child_process');
const { name: tmpDir } = tmp.dirSync();
const tmpFile = resolve(tmpDir, 'test.txt');

console.log(`DIR: ${tmpDir}`);
console.log(`FILE: ${tmpFile}`);
writeFileSync(tmpFile, 'Hello world');
execSync(`start notepad "${tmpFile}"`);

If it works, you should see the text file. If not, hopefully we’ll see an error.

On a related note, you may be able to look in the tmpDir on your system, and see if you find other attempted deploys.

Okay, probably getting there then :slight_smile:

Error: Cannot find module 'tmp'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)
at Function.Module._load (internal/modules/cjs/loader.js:507:25)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (internal/modules/cjs/helpers.js:20:18)

Ah, sorry, I think you might have to do one more step first, and install the node packages:

cd /your/project/directory
npm install

Then try to run the tmp stuff again.

Moving this to a private message, so we can share info. Will post the final solution back to this thread…

This is now solved with latest vapid-cli.
You just need to run:

npm -g install vapid-cli

Thanks for your support Scott