Getting started with Firebase Hosting (and GitHub Actions!)

แชร์
ฝัง
  • เผยแพร่เมื่อ 3 ก.ค. 2024
  • In this episode of Firebase Fundamentals, David East will show you how to get started with Firebase Hosting and how to get it started with GitHub Actions so you can generate a preview channel for every single pull request.
    Chapters:
    0:00 - Intro
    0:29 - Firebase CLI setup
    2:24 - Serving locally with the Emulator Suite
    3:22 - Deploying to Firebase Hosting
    3:52 - Configuration files
    4:13 - .firebaserc
    4:23 - Server redirects in firebase.json
    4:47 - Headers in firebase.json (Cross Origin Resource Sharing)
    5:09 - Preview channels
    5:44 - Manually deploying preview channels
    6:33 - Manually deleting preview channels
    7:00 - Setting up a GitHub repository
    8:22 - Creating GitHub Actions workflows
    8:50 - Setting up a build command in GitHub Actions
    9:42 - Setting up production deploys on merge
    10:11 - Triggering a preview channel on a pull request
    11:40 - Deploying to production on merge to main
    12:12 - More resources
    Resources:
    Node.js → goo.gle/3NL0vv7
    Java → goo.gle/3u8xDFd
    Next.js → goo.gle/3DWwx2N
    Firebase CLI → goo.gle/3ilEILs
    Firebase.json → goo.gle/3NRFgb1
    HTTP 301 → goo.gle/3ub4Gs5
    HTTP 302 → goo.gle/3x6Odav
    Cross Origin Resource Sharing (CORS) → goo.gle/3javFxE
    Preview channels → goo.gle/3Jbi9Vc
    GitHub Actions → goo.gle/37eZhY6
    Setting up preview channels with GitHub Actions → goo.gle/3Ja1IIz
    Catch more Firebase Fundamentals → goo.gle/Firebase-Fundamentals
    Subscribe to Firebase → goo.gle/Firebase
    #FirebaseFundamentals
    product: Firebase - Hosting; fullname: David East;
  • วิทยาศาสตร์และเทคโนโลยี

ความคิดเห็น • 70

  • @JavierSuzuki
    @JavierSuzuki ปีที่แล้ว +10

    This video was beyond amazing! A rock solid Firebase setup in 12 mins 🙌
    Thanks so much David!!!
    Truly looking forward to more of your videos!!

    • @Firebase
      @Firebase  ปีที่แล้ว +2

      Thank you for your kind words!
      We look forward to making more videos for you to enjoy.

  • @Arda-ff2qb
    @Arda-ff2qb ปีที่แล้ว +1

    great resource. both simple and detailed explanation at the same time. thank you!

  • @nicklesseos
    @nicklesseos 2 ปีที่แล้ว +4

    This guy makes the best videos on this channel, here's another banger

    • @Firebase
      @Firebase  2 ปีที่แล้ว

      David is great! If you like his videos you should check out his podcast series.

  • @justttn
    @justttn 2 ปีที่แล้ว +4

    Awesome work David ! 🔥

  • @BradEvans
    @BradEvans 2 ปีที่แล้ว +3

    I'm excited for this series

  • @theace9607
    @theace9607 2 ปีที่แล้ว +4

    Been looking for a good guide to properly set up hosting with github, much appreciated

    • @Firebase
      @Firebase  2 ปีที่แล้ว

      We're happy to hear our guide was able to assist in properly setting up hosting with GitHub! Thanks for watching 😎

  • @shauryaaher6175
    @shauryaaher6175 2 ปีที่แล้ว +4

    I like you, David. Your work is excellent.

  • @shauryaaher6175
    @shauryaaher6175 2 ปีที่แล้ว +4

    Nice. The GitHub Actions CI automation tests are great for me.

  • @X86developer
    @X86developer ปีที่แล้ว

    Amazing job on these videos.

  • @proflead
    @proflead 25 วันที่ผ่านมา

    Firebase is the best! Love it! Thanks!

  • @radomirpiatkowski829
    @radomirpiatkowski829 4 หลายเดือนก่อน +2

    Amazing video, but i really recommend to add part about adding secrets and how to edit the workflow to work, because it is also better option not to publish firebase API key and other firebase stuff to repository on github, and without it the workflow will deploy a blank site.

  • @chandanagarwal2827
    @chandanagarwal2827 2 ปีที่แล้ว +2

    okay life is going to be a little easy now after this series

  • @ChrisMercredi
    @ChrisMercredi ปีที่แล้ว +1

    Great video, thanks!

    • @Firebase
      @Firebase  ปีที่แล้ว

      We're glad you liked the video, Chris! Be sure to check out the link below for more tips and tutorials for getting started with Firebase Hosting:
      goo.gle/3PCAWwA
      Happy learning 🙂

  • @aldaineclarke755
    @aldaineclarke755 ปีที่แล้ว +1

    Thanks alot..This is really great

    • @Firebase
      @Firebase  ปีที่แล้ว

      We're happy to hear this, Aldaine! Thanks for the wonderful feedback 😁

  • @boris1509
    @boris1509 ปีที่แล้ว

    Great video!

  • @shauryaaher6175
    @shauryaaher6175 2 ปีที่แล้ว +4

    I'm waiting for your Firebase Hosting series.

  • @softwareengineer9435
    @softwareengineer9435 2 ปีที่แล้ว +2

    thank you

  • @alex-desroches
    @alex-desroches 2 ปีที่แล้ว +2

    the firebase login:add command... wow. I need this since 6 months and did not know about it :) thank you for the hint saves time when using work account vs personal projects account.

    • @Firebase
      @Firebase  2 ปีที่แล้ว +1

      Glad to hear that the guide was helpful, Alexandre 🙌

  • @erik9817
    @erik9817 7 หลายเดือนก่อน

    Amazing! Would be interesting to know how to avoid storing firebase secrets inside the repository yet be able to access those secrets inside the build actions.

  • @HyperbrainSolutions
    @HyperbrainSolutions ปีที่แล้ว +1

    Nice content

    • @Firebase
      @Firebase  ปีที่แล้ว

      We're glad that you've enjoyed this video! Don't forget to check out the video description for more helpful resources 😎

  • @waystogeek5879
    @waystogeek5879 2 ปีที่แล้ว +1

    thanks

  • @anggoran7398
    @anggoran7398 2 ปีที่แล้ว

    Thank you the staging deploy is so helpful, but I don't know why are you using Next as an example project, while Next is identic as an SSR frontend framework?

  • @1dosstx
    @1dosstx 2 ปีที่แล้ว

    I am trying to follow along, but I get an error: Error: [nitro] Rollup error: Could not resolve '../../service-account.json' from server/utils/firebase.js . Do you have a video yet on using cloud functions and firebase deployment with live preview channel? I have service account ignored in gitignore file. Thanks for your help

  • @Tech_Advisor_to_CXOs
    @Tech_Advisor_to_CXOs ปีที่แล้ว

    Where can I find the advanced video?

  • @user-de6ls7xu9y
    @user-de6ls7xu9y 7 หลายเดือนก่อน

    How do I deploy the getting started video by david with fb hosting. The getting started has webpack with dist folder. Should i give dist as the folder location instead of out folder.

  • @abbashaidari8313
    @abbashaidari8313 หลายเดือนก่อน +1

    can I merge from the terminal as well?

  • @michaelcasile1036
    @michaelcasile1036 ปีที่แล้ว

    Thanks to this video ... I got it running quickly (just stored Angular files as that is my Firebase client). What I am getting is that my browser (chrome) calls it a dangerous site and warns about putting in passwords. Is there something I can do to fix that?

  • @kiranbansode4545
    @kiranbansode4545 2 ปีที่แล้ว +1

    How to use cloud build to deploy an app to one of firebase's preview channel ? I tried but failed to do so. For now I'm using live channel but I want reserve that for stable branch.

    • @Firebase
      @Firebase  2 ปีที่แล้ว

      Hi Kiran, Check out this documentation to help you get started: firebase.google.com/docs/hosting/manage-hosting-resources

  • @karthikpuvvula
    @karthikpuvvula 3 หลายเดือนก่อน

    what to input here if the repo is inside an organization ?
    ? For which GitHub repository would you like to set up a GitHub workflow? (format: user/repository)

  • @mahabalperiyapatnashankarn94
    @mahabalperiyapatnashankarn94 ปีที่แล้ว

    great guidance, but I have a problem... my hositng is suceccful but I am seeing the firebase hosting complete page when I click the URL of my app.... but not my application. can anyone help me out of this....

  • @coders_Infinite
    @coders_Infinite ปีที่แล้ว +1

    can you pls do a video for angular universal Firebase Hosting (and GitHub Actions!)

  • @drfernando4647
    @drfernando4647 ปีที่แล้ว

    I don’t know if I did anything wrong but after I deploy my website it doesn’t let me test the customer login page it just downloads the information and everything we did on that page please do you have a solution or am I doing something wrong here?

  • @learnwithpaidi8185
    @learnwithpaidi8185 2 หลายเดือนก่อน

    3:23 i followed the same procedure but a instead of my project it host an page which says " Welcome
    Firebase Hosting Setup Complete
    You're seeing this because you've successfully setup Firebase Hosting. Now it's time to go build something extraordinary!"

  • @rahulsriram6295
    @rahulsriram6295 ปีที่แล้ว

    Is there something similar for GitLab Actions?!

  • @musigahstallone
    @musigahstallone ปีที่แล้ว

    hey how can I delete a web app that i deployed to the web

  • @avi12
    @avi12 หลายเดือนก่อน

    That's a great tutorial, but I was wondering how could I set up a preview channel that isn't short-lived (also not tied to a GitHub Action)
    Basically, suppose I want to generate such a URL, put it hardcoded in my project, build a zip, and send it to test users, therefore I wouldn't want the URL to be invalid after some time

  • @arifrozakirejadadi
    @arifrozakirejadadi 2 ปีที่แล้ว

    Ingin belajar tp belum paham, tanks

  • @lzhiba6736
    @lzhiba6736 2 ปีที่แล้ว

    Iam planning to create an App download campaign, I need help to upload the conversion tracking code in order to track my DOWNLOADS , how can I reach the Firebase team support !!

  • @shaileshrkumar6813
    @shaileshrkumar6813 7 หลายเดือนก่อน

    It worked !

  • @faheemahmadofficial7701
    @faheemahmadofficial7701 2 ปีที่แล้ว +2

    no sir...tell us how to host flutter app without CIi

  • @lethalgaming789
    @lethalgaming789 5 หลายเดือนก่อน

    I need an SSR deployment for a nextjs project on firebase. Suggest a full deployment source.

  • @oalbert2845
    @oalbert2845 2 ปีที่แล้ว

    === Hosting Setup
    Your public directory is the folder (relative to your project directory) that
    will contain Hosting assets to be uploaded with firebase deploy. If you
    have a build process for your assets, use your build's output directory.
    ? What do you want to use as your public directory? y
    ? Configure as a single-page app (rewrite all urls to /index.html)? Yes
    ? Set up automatic builds and deploys with GitHub? No
    Error: An unexpected error has occurred.
    Can anyone help me , I check the Y is really in the fold

  • @Nad-gd1of
    @Nad-gd1of 5 หลายเดือนก่อน

    Why Java needed, you said? Thx

  • @amicacofficiel646
    @amicacofficiel646 2 ปีที่แล้ว

    i need to add paiement but hi wan't work with me sir

  • @BenBeckers
    @BenBeckers 7 หลายเดือนก่อน

    I can't get this to work.
    It seems that my public folder is not taken into account when running locally. I see that you did not change anything and it magically works.

  • @somayajisubs
    @somayajisubs 2 ปีที่แล้ว +3

    looking forward to cloud run with fb hosting with dynamic web app caching using express js

  • @benimarunikaido
    @benimarunikaido ปีที่แล้ว

    can we download files deployed on firebase?
    i accidentally lost from my PC.
    please help.

    • @Frank_van_Puffelen
      @Frank_van_Puffelen ปีที่แล้ว

      There's no specific API for this, but you can crawl the web site as shown here: stackoverflow.com/questions/26286339/pull-lost-code-from-firebase-hosting-deployment

  • @nee71
    @nee71 2 หลายเดือนก่อน

    please create for nextjs 14 with github repo workplace demo

  • @karthikdasari7205
    @karthikdasari7205 2 ปีที่แล้ว

    Give me am example for hosting django/flask applications in firebase

    • @DavidEast
      @DavidEast 2 ปีที่แล้ว

      Got one right here!
      th-cam.com/video/t5EfITuFD9w/w-d-xo.html
      medium.com/firebase-developers/hosting-flask-servers-on-firebase-from-scratch-c97cfb204579

  • @shauryaaher6175
    @shauryaaher6175 2 ปีที่แล้ว +1

    There's something you need to fix in the Firebase Hosting GitHub Action. Whenever I make a tiny, little change, like updating dependencies, the GitHub Action gets triggered and creates a preview channel or deploys to the live channel. I have to cancel the check to not let this happen. Is there a change I should make in the YAML file or will you guys fix that issue yourselves.

  • @_GabrielNexT
    @_GabrielNexT 2 ปีที่แล้ว +5

    When the problem is frontend, call David.

  • @lost-prototype
    @lost-prototype ปีที่แล้ว

    Can you add jetbrains space support for generating flows?

  • @pmichaelbender
    @pmichaelbender 2 ปีที่แล้ว

    If you and the other Fundamentals creators can put the example of what was use in the video. Please and thank you.

    • @pmichaelbender
      @pmichaelbender 2 ปีที่แล้ว

      It make it easier to see what viewers might have missed or can't see in the files on the video.

  • @jamaasaranbat6929
    @jamaasaranbat6929 4 หลายเดือนก่อน

    i am gettin 404, unknown service account 😢

  • @mohebjami
    @mohebjami 4 หลายเดือนก่อน

    it's not working i try it hundred times after uploding all of data when i get the link it sat Firebase Hosting Setup Complete
    You're seeing this because you've successfully setup Firebase Hosting. Now it's time to go build something extraordinary!
    and it not opne the web