docs: add installation instructions to run locally
This commit is contained in:
parent
3d8de1700f
commit
adae1480c5
|
@ -0,0 +1 @@
|
||||||
|
/node_modules
|
50
README.md
50
README.md
|
@ -23,25 +23,25 @@ In order to get the Google api keys required for the oauth follow these steps:
|
||||||
|
|
||||||
### Client ID
|
### Client ID
|
||||||
|
|
||||||
1) Create a new project at https://console.cloud.google.com/
|
1. Create a new project at https://console.cloud.google.com/
|
||||||
|
|
||||||
2) Head over to the API library and enable
|
2. Head over to the API library and enable
|
||||||
the <a href="https://console.cloud.google.com/apis/library/streetviewpublish.googleapis.com">Street View Publish
|
the <a href="https://console.cloud.google.com/apis/library/streetviewpublish.googleapis.com">Street View Publish
|
||||||
API</a>
|
API</a>
|
||||||
|
|
||||||
3) Select 'Create Credentials', select 'User Data', enter any app name/email.
|
3. Select 'Create Credentials', select 'User Data', enter any app name/email.
|
||||||
|
|
||||||
4) Enable the 'Street View Publish API' scope. You won't need any sensitive scopes.
|
4. Enable the 'Street View Publish API' scope. You won't need any sensitive scopes.
|
||||||
|
|
||||||
5) Select 'Web application' for type, and name it anything.
|
5. Select 'Web application' for type, and name it anything.
|
||||||
|
|
||||||
6) Add http://localhost:7000 to authorized javascript origins. (If you are running on another domain/port, replace
|
6. Add http://localhost:7000 to authorized javascript origins. (If you are running on another domain/port, replace
|
||||||
localhost)
|
localhost)
|
||||||
|
|
||||||
7) Add http://localhost:7000/auth/ to authorized redirect URIs (If you are running on another domain/port, replace
|
7. Add http://localhost:7000/auth/ to authorized redirect URIs (If you are running on another domain/port, replace
|
||||||
localhost)
|
localhost)
|
||||||
|
|
||||||
8) You should now copy the Client ID into the config.json file.
|
8. You should now copy the Client ID into the config.json file.
|
||||||
|
|
||||||
### Client Secret
|
### Client Secret
|
||||||
|
|
||||||
|
@ -50,15 +50,15 @@ and copy that to your config.json.
|
||||||
|
|
||||||
### Consent Screen
|
### Consent Screen
|
||||||
|
|
||||||
1) Select 'OAuth consent screen', use any name/email
|
1. Select 'OAuth consent screen', use any name/email
|
||||||
|
|
||||||
2) Make sure the authorized domain and email is correct, then select 'Save and Continue'.
|
2. Make sure the authorized domain and email is correct, then select 'Save and Continue'.
|
||||||
|
|
||||||
3) Make sure the Street View Publish API scope is enabled, if not, add it!
|
3. Make sure the Street View Publish API scope is enabled, if not, add it!
|
||||||
|
|
||||||
4) For test users, add the email address of the account where you want to upload 360 photos.
|
4. For test users, add the email address of the account where you want to upload 360 photos.
|
||||||
|
|
||||||
5) **Make sure to also copy the client ID into index.html**, after '&client_id=' and before '&scope', if needed, change
|
5. **Make sure to also copy the client ID into index.html**, after '&client_id=' and before '&scope', if needed, change
|
||||||
the port and domain here as well.
|
the port and domain here as well.
|
||||||
|
|
||||||
### Config File
|
### Config File
|
||||||
|
@ -67,7 +67,7 @@ There are many options in the config file that might confuse you, so here's a si
|
||||||
through it.
|
through it.
|
||||||
|
|
||||||
| **Keys** | **Default values** | **Usage** |
|
| **Keys** | **Default values** | **Usage** |
|
||||||
|------------------|----------------------------|------------------------------------------------------------------------------------------------------------------------------------------------|
|
| ---------------- | -------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `https` | `false` (boolean) | This is an option whether if you want to enable https or not, this uses boolean values. `false` = http:// and `true` = https:// |
|
| `https` | `false` (boolean) | This is an option whether if you want to enable https or not, this uses boolean values. `false` = http:// and `true` = https:// |
|
||||||
| `host` | `localhost` (string) | Your host or domain, if you are hosting on a local machine, set this to `localhost`, if you are hosting this publicly, set it to your domain. |
|
| `host` | `localhost` (string) | Your host or domain, if you are hosting on a local machine, set this to `localhost`, if you are hosting this publicly, set it to your domain. |
|
||||||
| `port` | `7000` (integer) or `null` | Your port, if are running this as a public instance, set this to `null` |
|
| `port` | `7000` (integer) or `null` | Your port, if are running this as a public instance, set this to `null` |
|
||||||
|
@ -114,6 +114,28 @@ Your **authorized JavaScript origin** would be: `http://localhost:7000`
|
||||||
|
|
||||||
Your **authorized redirect URIs** would be: `http://localhost:7000/auth/` (don't forget the slash after `auth`)
|
Your **authorized redirect URIs** would be: `http://localhost:7000/auth/` (don't forget the slash after `auth`)
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
1. Clone the repository
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git clone https://github.com/moom0o/PhotoSphereStudio.git
|
||||||
|
```
|
||||||
|
|
||||||
|
2. Install the dependencies
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npm install
|
||||||
|
```
|
||||||
|
|
||||||
|
3. Update the `config.json` file in the root directory of the project and fill it with the required information (clientId, clientSecret, etc.)
|
||||||
|
|
||||||
|
4. Start the server
|
||||||
|
|
||||||
|
```bash
|
||||||
|
node index.js
|
||||||
|
```
|
||||||
|
|
||||||
## Support
|
## Support
|
||||||
|
|
||||||
If you have any questions about how to set this up or about the source code, feel free to ask either **moom0o** (
|
If you have any questions about how to set this up or about the source code, feel free to ask either **moom0o** (
|
||||||
|
|
Loading…
Reference in New Issue