How to Deploy a PERN application on Heroku

Поділитися
Вставка
  • Опубліковано 3 жов 2024

КОМЕНТАРІ • 157

  • @TheMrsjacoblautner
    @TheMrsjacoblautner 2 роки тому +7

    You're a life saver! Been looking for a tutorial on deploying with the same stack. Thanks for the great explanations and context

  • @Darkfire889
    @Darkfire889 3 роки тому +8

    Spent hours trying to figure out why it worked locally and not in Heroku. 503 Error in chrome, PostgreSQL error: no pg_hba.conf entry for host. Here is the fix....
    Heroku needs this line when creating the pool:
    ssl: {
    rejectUnauthorized: false,
    },
    This will fix the Heroku problem but break the dev server. Create a new pool conditionally for production/dev like this:
    const pool =
    process.env.NODE_ENV === "production"
    ? new Pool({
    connectionString: prodConfig,
    ssl: {
    rejectUnauthorized: false,
    },
    })
    : new Pool({
    connectionString: devConfig,
    });

    • @ThePyromaniac84
      @ThePyromaniac84 3 роки тому

      Boy do i love you, had the same thing, i was getting error 503

    • @ThePyromaniac84
      @ThePyromaniac84 3 роки тому +1

      This is the code i used to ensure it worked on local server too
      const pool =
      process.env.NODE_ENV === "production"
      ? new Pool({
      connectionString: proConfig,
      ssl: {
      rejectUnauthorized: false,
      },
      })
      : new Pool({
      connectionString: devConfig,
      });

    • @AnotherMlbbPlayer
      @AnotherMlbbPlayer 3 роки тому

      i love you man it worked........... i was trying to solve this errror from last 15 days

    • @PinPonStyle
      @PinPonStyle 3 роки тому +1

      thank you. You just save me

    • @zacharyzawaideh8079
      @zacharyzawaideh8079 2 роки тому

      You are amazing. Thank you so much, you saved my day for real I finished the whole tutorial and was super confused at why it would not work. Thank you so much

  • @thefantasynuttwork
    @thefantasynuttwork 4 роки тому +5

    Would love to see a forgot password video for the PERN app we have made. Thanks for the content!

  • @henryli85
    @henryli85 3 роки тому +2

    From one Henry Li (Ly) to another, this was an amazing tutorial! Thank you!

  • @KahramanMustafa
    @KahramanMustafa 2 роки тому +2

    Another great tutorial, thank you Henry, suppose name from package author info :)! I have watched the PERN tutorial prior to this tutorial, it was also great. I was looking how to deploy my react and node apps to an online server in a correct way for a long time. Your content, way of explaining and reasoning are well and easy to comprehend. Selected topics chosen well, they are practical fields widely seeked but rarely found enough info about them

    • @astkh4381
      @astkh4381 2 роки тому

      hi can you explain what is .env.NODE_ENV 16:18?We dont have it in our .env

    • @abishek_stuff
      @abishek_stuff Рік тому

      ​@@astkh4381 not all environment variables need to come from your .env file, some can be set during the process initialisation, some can be set by the system itself, etc. One of those is process.env.NODE_ENV, which is set as PRODUCTION when built and run, vs run in npm run dev

  • @amiraskari8655
    @amiraskari8655 4 роки тому +1

    There is really lack of content and tutorials on PERN stack. I really learned from every single video on your channel. Please keep up the great work. Hope you wont stop making these.
    Thanks :)

  • @bibasniba1832
    @bibasniba1832 4 роки тому +2

    Dear Henry,
    I am so glad I stumbled upon your channel. I’ve added every single one of your videos to a playlist to watch, and I just subscribed.
    Thank you so much!!!

  • @ahmed.hammami590
    @ahmed.hammami590 2 роки тому

    you are the real mvp, i started at your pern tutorial video like a month ago, now that i undertsand react and node better i'm trying to deploy it on heroku and connect it to my salesforce org, been hard stuck until i came back to youtube and found this video and i was really happy to find out it's the same channel, your work is appreciated and helpful ! thank you so very much

    • @astkh4381
      @astkh4381 2 роки тому

      hi can you explain what is .env.NODE_ENV 16:18?We dont have it in our .env

    • @OscarGarcia-dg6is
      @OscarGarcia-dg6is Рік тому

      @@astkh4381 I'm at the same place. I think you have to add this at the Config Vars on the Heroku Settings. That's what I did.

  • @RokasZebrauskas
    @RokasZebrauskas 4 роки тому +1

    I would just like to thank you for the tutorial , it helped me a lot since there are not many PERN deployment tutorials, but yours is spot on ! Good explanations and everything :)

  • @bv9876
    @bv9876 2 роки тому

    Author plz come back. You did great lessons. I am russian and I don't understand english well, but your lessons are understood perfectly.

    • @mori7423
      @mori7423 2 роки тому

      Если не знаешь английский, то это не твоё

    • @bv9876
      @bv9876 2 роки тому

      @@mori7423 I don't agree )

    • @mori7423
      @mori7423 2 роки тому

      @@bv9876 tak po angliiski ne pishut))))

  • @nwkwok
    @nwkwok 3 роки тому

    Henry - your tutorials are so helpful. Thank you so much! Learning so much from the way your breakdown your tutorials.

  • @youssefelshabrawy7310
    @youssefelshabrawy7310 2 роки тому

    YOU ARE A LEGEND!

  • @EaglesFly101
    @EaglesFly101 3 роки тому

    As a junior dev doing fun projects on the side to continue improving my skills, this is great stuff! I've been looking to deploy on Heroku with this specific stack so this is perfect, as well as the JWT videos you have. Thank you!

  • @AdamAdam-xy6vh
    @AdamAdam-xy6vh 4 роки тому

    Your videos have taught me so much man. Amazing stuff.

  • @loicderty4555
    @loicderty4555 4 роки тому

    nice tutorial ! PERN tutorials are so rare ! thanks you

  • @orange_coconut3537
    @orange_coconut3537 3 роки тому

    Hi Henry, Thank you so much for this video. It helped me really when I deployed an app Heroku for the first time. It was so amazing that I introduced it and talked about what I learned in a tech blog in Japanese. If it is unacceptable, please let me know. I will remove it immediately. Thank you.

  • @alglaser7296
    @alglaser7296 4 роки тому

    Thank you so much!!! best teacher ever..!!!!!!!!!

  • @kyungssew3999
    @kyungssew3999 3 роки тому

    Thank you so much for this tutorial. It really helps me a lot!

  • @yousefmedhat56
    @yousefmedhat56 3 роки тому

    Thank you, Henry. You're great❤

  • @jennifermisewicz3259
    @jennifermisewicz3259 3 роки тому

    This helped me out a ton. Thank you!

  • @volkanongun1112
    @volkanongun1112 3 роки тому

    great tutorials Henry, watched all of them. Thanks for sharing!

  • @gerardosalasm6213
    @gerardosalasm6213 3 роки тому

    thank you for the tutorial,

  • @BlortNet
    @BlortNet 4 роки тому +1

    Nice work man

  • @devops3249
    @devops3249 2 роки тому +2

    My Site is up on Heroku as you instructed but database add delete or update is not working.Anything I have to look upon it? Thanks.

  • @vasiliv6872
    @vasiliv6872 3 роки тому +4

    Thank you for the tutorial!
    I have a problem, when I try to open the app at Heroku I get error: Not found

  • @yasinnkhann
    @yasinnkhann 3 роки тому +2

    I followed all your instructions. It works on my local server but when I deploy it I get, Failed to load resource: the server responded with a status of 503 (Service Unavailable)
    react_devtools_backend.js:4049 Unexpected token < in JSON at position 0

  • @kage-musha1702
    @kage-musha1702 2 роки тому

    would be really awesome if you do a tutorial on React Routers :)
    thank you for this tut btw

  • @dimitartanev97
    @dimitartanev97 3 роки тому

    Thank you, man.

  • @kehindefasunle4933
    @kehindefasunle4933 2 роки тому

    Fantastic 👏

  • @karanbhatia6712
    @karanbhatia6712 3 роки тому

    Thanks alot! Love

  • @ubaidkhan426
    @ubaidkhan426 3 роки тому

    Thanks buddy!

  • @huletech
    @huletech Рік тому

    hi henry long time no see when do you back to your youtube channel we miss your video so much

  • @DOPTRICK
    @DOPTRICK 4 роки тому +2

    Plz create full course of PERN stack. Or recommond me something plz. I am working on project and I would love to work with you.

  • @mandihaase2744
    @mandihaase2744 3 роки тому +3

    What is the best way to troubleshoot when my app is getting a 503 error? I am getting an unexpected token < in JSON at position 0 (my console is showing the error at const response = await fetch(`/todos`); it doesn't seem like the getTodos is working in production, even though it works locally. Any ideas on the best way to troubleshoot?

  • @KimFajardoPH
    @KimFajardoPH 4 роки тому +2

    Hello! I followed all your steps but I am facing a problem after heroku deployment. When I open my app on heroku, I get a "Not Found". Any fix for that? What could I have missed?

    • @JacobSwetmore
      @JacobSwetmore 4 роки тому

      I have the same issue! Did you manage to fix it?

  • @jeroldlim816
    @jeroldlim816 2 роки тому

    i deployed the completed project to heroku, but it doesnt work. i get failed to load resource, server responded 503 and uncaught in promise "

  • @xyxy-b3h
    @xyxy-b3h Рік тому +1

    Bro are you still alive ? Why you stopped posting pern ?!

  • @therichardchannel
    @therichardchannel 2 роки тому +1

    Anyone know why when I have it deployed on Heroku, the fetching routes aren't working? I can't GET, POST, or PUT, although the form shows and should work. It works fine on localhost:5000

    • @KahramanMustafa
      @KahramanMustafa 2 роки тому

      I have the same problem, seeking solutions

    • @KahramanMustafa
      @KahramanMustafa 2 роки тому

      I found a solution among comments. I have configured in the db.js, "proConfig" object, it worked.
      const proConfig = {
      connectionString: process.env.DATABASE_URL, // Heroku addons
      ssl: {
      rejectUnauthorized: false,
      }
      }

  • @harryminnie6
    @harryminnie6 4 роки тому

    to clear the cache issue. what worked for me was I just shut down my front end server and back end server. I then started my back end server first followed by my front end. it all seems to be working. I did not have to re-install my package.json and dependencies.

  • @DJ-vn2xe
    @DJ-vn2xe 4 роки тому

    Thanks for the wonderful tutorial dude..it would help me a lot...!
    would this work fine if I used routes in my react app?

  • @Jun-zq3bn
    @Jun-zq3bn Рік тому +1

    please do a video deploying on render now that heroku is no longer free

  • @OscarGarcia-dg6is
    @OscarGarcia-dg6is 2 роки тому

    Can you make a video showing what VSCODE Extensions you have installed? I've been watching your videos and there's some stuff happening when you hit save that my Extensions don't to. :/ I have to be very careful with some parenthesis and brackets.

  • @akshaybisht3801
    @akshaybisht3801 2 роки тому

    Sir I have a application on MySQL sequelize, React, Node and PhpMyAdmin..How to deploy the application on heroku for MySQL.

  • @chistoperez
    @chistoperez 2 роки тому +1

    FIX for error 503 (Service Unavailable) (ADD, UPDATE, DELETE not working) on db.js
    const proConfig = {
    connectionString: process.env.DATABASE_URL,
    ssl: { rejectUnauthorized: false },
    };
    const pool = new Pool( proConfig );

  • @MrPogi-lf5gz
    @MrPogi-lf5gz 4 роки тому +2

    Can you also do a tutorial on Payment integration? And or image upload?

    • @TheQuackLearner
      @TheQuackLearner  4 роки тому +1

      Thanks for the suggestion, I definitely look into those things!

    • @tcdesports5673
      @tcdesports5673 4 роки тому

      @@TheQuackLearner I'm also looking forward to an image upload tutorial using PERN Stack

  • @oabouassy
    @oabouassy 3 роки тому +2

    I managed to deploy my app, but once i open the app link, it crashes and error 503 in console

    • @pavloaleksyeyev5065
      @pavloaleksyeyev5065 3 роки тому

      @Omar, did you resolve this error? I ran into the same issue

    • @oabouassy
      @oabouassy 3 роки тому +1

      @@pavloaleksyeyev5065 check ssl option when creating postgresql Client instance . This was the problem

    • @AnotherMlbbPlayer
      @AnotherMlbbPlayer 3 роки тому

      @@oabouassy i am still getting this 503 error

    • @petarp3938
      @petarp3938 3 роки тому +1

      @@oabouassy Can you be more specific?

    • @oabouassy
      @oabouassy 3 роки тому

      @@petarp3938 I solved it bro thanks

  • @Supinpa
    @Supinpa 2 роки тому +1

    If anyone is using this with the previous JWT tutorial and you're getting a Unexpected JSON Token error, your JWT secret might not be getting pushed up to Heroku, what I did to fix this was to run this command: heroku config:set jwtSecret='mysecret!@' and it all started working properly.

  • @jordanfox7751
    @jordanfox7751 2 роки тому

    Is heroku good enough to handle the react side of an application? It seems this way works only with static applications, would someone be able to elaborate on what this means? is there any drawback of using heroku for both your front-end and back-end of a pern application? will there be scenarios where you must use another service for your front end?

  • @vasantharajants2917
    @vasantharajants2917 4 роки тому +1

    This is a great tutorial but i have a problem after changing the proxy in package.json and deleting the package-lock.json and nodemodules i ran the command npm i and then i ran the server but it's showing the error:Failed to load resource: the server responded with a status of 401 (Unauthorized)

    • @tcritt
      @tcritt 4 роки тому

      Same here

  • @jumbo999614
    @jumbo999614 3 роки тому

    Please make another video about Express-Validator. I tried to use it with react and routes controller and it didn't work.

  • @albertomatehuala5608
    @albertomatehuala5608 4 роки тому

    It's an awesome project, but the node js version Changed a lot 'cause I had to use the specific version of this project on my current project, due to the index (server) never started or at least never catched the requests, that problem gave me a 503 code in heroku , to solve the problem just use the exact version of this project

  • @BlissAden
    @BlissAden 3 роки тому

    Can you push to heroku with only a backend node server like what you shown in the video?

  • @juilipotdar8664
    @juilipotdar8664 4 роки тому

    Can you show how to deploy using GitHub? How to do continuous deployment while developing?

  • @kackupa752
    @kackupa752 4 роки тому

    I have a blank root page; the landing, routing and login all work but my root is empty; Did I miss something? Also, my JWT fails authorization on reloading the web page, only when run through the server with static file or deployed to production. Anyone come up with a solution?

  • @wisammozalbat6170
    @wisammozalbat6170 3 роки тому

    Hi, all my client folder just got replaced for a create-react-app new file

  • @bhavyachopra9973
    @bhavyachopra9973 4 роки тому

    The local psql command could not be located. Can you let me know I tried changing the path

  • @stjepanvukelic2253
    @stjepanvukelic2253 2 роки тому

    anyone knows why i get empty page when I open localhost:5000?

  • @RoknRolls
    @RoknRolls 2 роки тому

    Why is this impossible to do using Digital Ocean? I can't find a guide anywhere for a PERN stack deployment that gets into this video's level of detail

    • @lifeisbeautifu1
      @lifeisbeautifu1 2 роки тому

      ua-cam.com/video/xqHyMAlRtYw/v-deo.html&t heres the video on how to deploy node.js backend with postgres to DigitalOcean in great detail

  • @eazyvegas
    @eazyvegas 3 роки тому

    King

  • @Dinko15
    @Dinko15 Рік тому

    Hey Stoic, Im getting a weird issue with my heroku on startup. Is there a way we can correspond ? Its related to my router, its not grabbing anything from the backend.

    • @Dinko15
      @Dinko15 Рік тому

      I swear im not a bot I just hated the google plus era of having your first and last name

  • @sladky8268
    @sladky8268 2 роки тому

    error SSL: certificate verify failed

  • @931112
    @931112 4 роки тому +1

    Hi! would this work if im using sequelize + postgres? Thanks for the tutorial!

    • @931112
      @931112 4 роки тому +1

      YES IT DOES! thanks!

  • @raflyananda8492
    @raflyananda8492 2 роки тому

    Hey thank you so much for the tutorial, really helpful and well explained, but i'm still a little bit confused about the git in the local dev, when we do create-react-app, react already initialized a git repo on that folder(client), and when we were making the server (server folder), we also init a git repo, so my question is how does we interact with the code with git. example such as when making a change, do we need to do git command on both folders (git add . commit etc ) or just do it on the main one at the root of the project ? if so, what do we do to the git on the server and client folder ? sorry if i didn't explain it clearly

    • @charleslamb5810
      @charleslamb5810 2 роки тому

      Rafly... great question. I stumbled upon your question at the perfect time since I struggled with this issue for days! If you have figured this out already disregard but I know it's a good possibility others are struggling with this as well...
      So... I don't think it was mentioned in this video(at least I don't remember it) but you are 100% correct that when you create react app it initializes a git repo, and this WILL cause conflicts because a git repository INSIDE of another git repository will be ignored by git. This git repository (the one buried inside of another one) is called a submodule. Like I said above submodules are always ignored by git so when you go to github you won't even see the contents of the submodule.
      Now here is the solution: when you have a submodule, like the client for instance all you have to do.... is delete the .git file. Now this is a hidden file so you will not see it with ls. Type ls -a and you will see the .git rear its ugly head. Delete this .git folder and you no longer have a submodule. At this point anytime you add to the staging area or git commit etc. It will include all folders on the project. It must have been done for the project on this video but was accidentally left out I suppose. What WAS done on the video is he took all of the contents of the server folder and put it into the root, this made one root level package.json and one root level.git for the entire project. I hope that helped because it drove me nuts lol.

    • @raflyananda8492
      @raflyananda8492 2 роки тому +1

      @@charleslamb5810 hey sorry for the late reply, thank you so much really clear things up for me

  • @ailleine9484
    @ailleine9484 4 роки тому

    thank you so much for this series!! I've been following along since the to-do list and it's my intro to full stack, so I was very pleased to be able to be able to learn so much!
    I'm running into a problem @ the 25:00 mark re:clearing cache: when I restart my React app the database entries don't load, although I triple checked and should have completed the previous steps (in client I deleted node_modules/package-lock.json & ran npm install, didn't comment out window.location).
    console shows this error: JSON.parse: unexpected character at line 1 column 1 of the JSON data (e index.js:1, getTodos ListTodo.js:27). I haven't touched the component code besides shortening the URL cuz of the proxy & changing quotes to backticks--any idea what might be wrong?

    • @TheQuackLearner
      @TheQuackLearner  4 роки тому

      Hi ailleine! Is it possible you can pass me your code on GitHub so I can take a closer look at the problem?

    • @aileenwu1362
      @aileenwu1362 4 роки тому

      @@TheQuackLearner yes!! here it is: github.com/wua3/pern-todo

    • @TheQuackLearner
      @TheQuackLearner  4 роки тому

      ​@@aileenwu1362 , so the reason the react app didn't work was that the proxy was not added to the package.json yet. I fixed the issue by adding the proxy (you can start at 22:12 to see how to it is done) and I clear the cache by first deleting the package-lock.json and node_modules, second installing the packages back in the react application, and third turning back on my react app. Hopefully, this helps your issue. Feel free to reply if you continue to face a problem.

    • @aileenwu1362
      @aileenwu1362 4 роки тому

      @@TheQuackLearner yes! I had actually put the proxy into the root package.json and I understand now why it should be in the client one--thank you for your help!!

  • @worldwide6626
    @worldwide6626 Рік тому

    Make one on aws considering Heroku removed its free tier

  • @andrewbateman2282
    @andrewbateman2282 4 роки тому

    Great tutorial and code deployed OK. Just one question: when I enter a todo the list updates automatically but if I edit or delete a todo the list does not refresh itself - `window.location = "/"` is used after each operation, same as your code. I have to refresh to see the changes. Thanks.

    • @TheQuackLearner
      @TheQuackLearner  4 роки тому +1

      Hey Andrew, is it possible you can pass me your github code so I can take a closer look?

    • @andrewbateman2282
      @andrewbateman2282 4 роки тому +1

      @@TheQuackLearner Hi, thanks.
      github.com/AndrewJBateman/pern-stack-todo

    • @TheQuackLearner
      @TheQuackLearner  4 роки тому +2

      ​ Andrew Bateman so the problem is that a response is not being sent back by the server. The window.location can not be executed until a server does a res.send or res.json is returned. In your edit and delete server routes (index.js file) I notice you comment out the res.json. I fixed the issue by adding it back. Hopefully, that fixed your issue. Feel free to ask more questions if that didn't help your case. Anyway, I really like the documentation you set up!

    • @andrewbateman2282
      @andrewbateman2282 4 роки тому

      @@TheQuackLearner Thanks. It works now. Amazing, I was only looking in the client file for the problem and it was on the server side. Thanks againl

  • @bhargavgohil25
    @bhargavgohil25 2 роки тому

    is Procfile neccesary ? or not ?

  • @cerencetin936
    @cerencetin936 3 роки тому +1

    For anyone who is getting a "Not Found" error in the console when they click on the Add button, I found that mine was due to SSL enforcement.
    I have added "ssl: { rejectUnauthorized: false }" in db.js within new Pool under the connectionString code. This has worked for me.
    So, it should be as below:
    const pool = new Pool({
    connectionString:
    process.env.NODE_ENV === "production" ? proConfig : devConfig,
    ssl: { rejectUnauthorized: false }
    });

  • @cocytus.o_o
    @cocytus.o_o 3 роки тому

    Hi, When the logs of my pern app says "no pg_hba.conf entry for host , user, database, SSL off".
    Could you please help me resolve the error?
    Thank you.

    • @CounterScroll
      @CounterScroll 3 роки тому

      I think I just had the same error as you and I fixed it.
      The issue is that the connection to the database is missing a parameter.
      You must add a second parameter after connectionString, in the Pool({}) which is:
      ssl: {
      rejectUnauthorized: false
      }
      It is shown here in the docs.
      devcenter.heroku.com/articles/heroku-postgresql#connecting-in-node-js

    • @timothywongej
      @timothywongej 3 роки тому

      @@CounterScroll hello! do you know if this has any security issues? I'm getting the same issue but not sure if this isthe only work around?

    • @CounterScroll
      @CounterScroll 3 роки тому

      @@timothywongej Honestly I have no clue! Security is something I know the least about.
      Under the section I linked, they say "Alternatively, you can omit the ssl configuration object if you specify the PGSSLMODE config var: heroku config:set PGSSLMODE=no-verify.". So that may be the only other option.

  • @vladodjuric3347
    @vladodjuric3347 3 роки тому

    Is anybody else getting a timeout error when their app is deployed? My database is empty however whenever I try to add a new todo my request times out.

    • @leonseled
      @leonseled 3 роки тому

      Bit late but was facing the same issue and cause for my issue was that Heroku requires SSL. So in your db.js file add the SSL key. const prodConfig = {
      connectionString: process.env.DATABASE_URL, //heroku addon
      ssl: {
      rejectUnauthorized: false,
      },
      };

    • @henryli85
      @henryli85 3 роки тому

      @@leonseled you are the MVP

    • @henryli85
      @henryli85 3 роки тому

      devcenter.heroku.com/articles/heroku-postgresql#connecting-in-node-js
      had to use this documentation. Changed the const to client. I don't know why pool didn't work.
      const { Client } = require('pg');
      require("dotenv").config(); //using ENV variables in .env
      let client;
      const devConfig = `postgresql://${process.env.PG_USER}:${process.env.PG_PASSWORD}@${process.env.PG_HOST}:${process.env.PG_PORT}/${process.env.PG_DATABASE}`;
      if (process.env.NODE_ENV === "production"){
      client = new Client({
      connectionString: process.env.DATABASE_URL,
      ssl: {
      rejectUnauthorized: false
      }
      });
      } else{
      client = devConfig;
      }
      module.exports = client;

  • @MrPogi-lf5gz
    @MrPogi-lf5gz 4 роки тому +1

    Can you do this on DO?

    • @TheQuackLearner
      @TheQuackLearner  4 роки тому

      Hi brigz, what does DO stand for?

    • @MrPogi-lf5gz
      @MrPogi-lf5gz 4 роки тому +1

      @@TheQuackLearner Digital Ocean.

    • @TheQuackLearner
      @TheQuackLearner  4 роки тому

      @@MrPogi-lf5gz ah I see , unfortunately Digital Ocean and Heroku have there own way of deploying there code. Digital Ocean is a IAAS , so it actually provides you your own server; therefore, this usually results to more configuration. Perhaps this article can give you a good introduction => codeburst.io/ricky-figures-it-out-devops-deployment-using-express-postgres-and-digital-ocean-15c2d961340e . Good question

    • @MrPogi-lf5gz
      @MrPogi-lf5gz 4 роки тому +1

      @@TheQuackLearner thanks. Awesome channel by the way. Hope you keep adding contents into it!

  • @skks837
    @skks837 3 роки тому

    @The Stoic Programmer ur duscord server?

  • @zr60
    @zr60 2 роки тому

    You don't have to pull out your entire server folder.....

  • @7308440
    @7308440 3 роки тому +1

    MAKE SURE YOU ALSO ADD SSL TO YOUR CONFIG CODE!!!!
    if (process.env.NODE_ENV === 'production') {
    dbParams.connectionString = process.env.DATABASE_URL
    dbParams.ssl = {rejectUnauthorized: false}
    devcenter.heroku.com/articles/heroku-postgresql#connecting-in-node-js

    • @KahramanMustafa
      @KahramanMustafa 2 роки тому

      Thanks man, it works like a charm, that is the I am looking for. I have configured in the db.js, "proConfig" object.
      const proConfig = {
      connectionString: process.env.DATABASE_URL, // Heroku addons
      ssl: {
      rejectUnauthorized: false,
      }
      }

  • @codedamn
    @codedamn 4 роки тому +3

    Hi Henry! I'm here from your fCC video. I have a proposal which you might find relevant. What's your email address? I cannot find it anywhere.

  • @arupde6320
    @arupde6320 Рік тому +1

    are you alive ??

  • @astkh4381
    @astkh4381 2 роки тому

    thank you , but how your app understand is this porudction or not 16:18.And what is .env.NODE_ENV

  • @anyaecheebuka118
    @anyaecheebuka118 3 роки тому

    I added authentication and I can't seem to register or login. Throws an error