How do I reset google login configuration once I have set it for my meteor app?

后端 未结 5 1851
悲哀的现实
悲哀的现实 2021-02-01 23:58

I am learning meteor and have created a new app and installed accounts-core, accounts-google and accounts-ui. This worked as expected and prompted me to configure the google in

5条回答
  •  清酒与你
    2021-02-02 00:19

    First, add the service configuration package:

    meteor add service-configuration
    

    Then, in your app in the system folder (create it if you don't have one) add a file called service.js and in there add:

    // first, remove configuration entry in case service is already configured
    ServiceConfiguration.configurations.remove({
      service: "google"
    });
    ServiceConfiguration.configurations.insert({
      service: "google",
      clientId: "123456789",
      loginStyle: "popup",
      secret: "8j4ldfjSECRET-HEREalkjf8slk"
    });
    

    Further Reading:
    Meteor Docs - Login With External Service

提交回复
热议问题