faressoft / terminalizer

🦄 Record your terminal and generate animated gif images or share a web player
https://terminalizer.com
MIT License
15.31k stars 498 forks source link

"Error: Something went wrong, try again later" caused by nginx redirect #207

Open regisb opened 1 year ago

regisb commented 1 year ago

When sharing a recording to terminalizer.com, the command fails in every case:

$ terminalizer share myrecoding
Please enter some details about your recording
? Title Test
? Description Desc
? Tags such as git,bash,game linux

Error: 
  Error: Something went wrong, try again later

Hint:
  Use the --help option to get help about the usage

I added a console.log(response) to commands/share.js which shows that the error comes from the fact that terminalizer.com is redirecting to www.terminalizer.com:

  body: '<html>\r\n' +
    '<head><title>301 Moved Permanently</title></head>\r\n' +
    '<body bgcolor="white">\r\n' +
    '<center><h1>301 Moved Permanently</h1></center>\r\n' +
    '<hr><center>nginx/1.12.2</center>\r\n' +
    '</body>\r\n' +
    '</html>\r\n',
  [Symbol(kCapture)]: false
}

Changing the BASEURL to "https://www.terminalizer.com" in app.js solved the problem.

oliverkane commented 1 year ago

I am having this issue as well.

regisb commented 1 year ago

@faressoft would you like me to open a PR?

you-n-g commented 1 year ago

@regisb Thanks for your suggestion. I have submitted the PR. Hoping it will be merged soon.