mirror of
https://github.com/fazo96/markcloud.git
synced 2025-01-09 10:59:52 +01:00
use meteor settings instead of custom source file
This commit is contained in:
parent
92b14abe4d
commit
a17c88a0d0
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
settings.json
|
18
README.md
18
README.md
@ -20,17 +20,19 @@ since the apps now depends on Meteor's
|
||||
|
||||
#### Twitter Authentication
|
||||
|
||||
Create this file: `server/settings.coffee` with this content:
|
||||
Create a `json` file with this content:
|
||||
|
||||
```coffeescript
|
||||
Meteor.startup ->
|
||||
Accounts.loginServiceConfiguration.remove service : 'twitter'
|
||||
Accounts.loginServiceConfiguration.insert
|
||||
service: 'twitter'
|
||||
consumerKey: 'Your API key'
|
||||
secret: 'Your API secret'
|
||||
```json
|
||||
{
|
||||
"twitter" : {
|
||||
"apiKey": "your_twitter_api_key",
|
||||
"secret": "your_twitter_api_secret"
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
Now run or deploy the application with the `--settings yourfile.json` parameter.
|
||||
|
||||
Your users will now be able to login using twitter. You may want to disable the
|
||||
button if you don't configure twitter authentication.
|
||||
|
||||
|
@ -28,3 +28,11 @@ Accounts.emailTemplates.verifyEmail.text = (user,url) ->
|
||||
url = Meteor.absoluteUrl 'verify/'+token
|
||||
'''Welcome to MarkCloud! To activate your account, click on the \
|
||||
following link: '''+url
|
||||
|
||||
# Twitter configuration code
|
||||
Meteor.startup ->
|
||||
Accounts.loginServiceConfiguration.remove service : 'twitter'
|
||||
if Meteor.settings.twitter? then Accounts.loginServiceConfiguration.insert
|
||||
service: 'twitter'
|
||||
consumerKey: Meteor.settings.twitter.apiKey
|
||||
secret: Meteor.settings.twitter.secret
|
||||
|
Loading…
Reference in New Issue
Block a user