You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
4. If you are using nvm, run `$ nvm use` to set your Node version to 16.14.2
17
+
4. If you are using nvm, run `$ nvm use 16.14.2` to set your Node version to 16.14.2
18
18
5. Ensure your npm version is set to 8.5.0. If it isn't, run `npm install -g npm@8.5.0` to install it.
19
19
6. Navigate into the project folder and install all its necessary dependencies with npm.
20
20
@@ -27,12 +27,14 @@ _Note_: The installation steps assume you are using a Unix-like shell. If you ar
27
27
* For Windows and Linux: [MongoDB Installation](https://docs.mongodb.com/manual/installation/)
28
28
8.`$ cp .env.example .env`
29
29
9. (Optional) Update `.env` with necessary keys to enable certain app behaviors, i.e. add Github ID and Github Secret if you want to be able to log in with Github.
30
-
10. Run `$ npm run fetch-examples` to download the example sketches into a user called 'p5'. Note that you need to configure your GitHub Credentials, which you can do by following the [Github API Configuration](#github-api-configuration) section.
31
-
11. Enable Prettier in your text editor by following [this guide](https://prettier.io/docs/en/editors.html).
32
-
12.`$ npm start`
33
-
13. Navigate to [http://localhost:8000](http://localhost:8000) in your browser
34
-
14. Install the [React Developer Tools](https://chrome.google.com/webstore/detail/react-developer-tools/fmkadmapgofadopljbjfkapdkoienihi?hl=en)
35
-
15. Open and close the Redux DevTools using `ctrl+h`, and move them with `ctrl+w`
30
+
* See the [GitHub API Configuration](#github-api-configuration) section for information on how to authenticate with Github.
31
+
* See the [S3 Bucket Configuration](#s3-bucket-configuration) section for information on how to set up an S3 bucket
32
+
11. Run `$ npm run fetch-examples` to download the example sketches into a user called 'p5'. Note that you need to configure your GitHub Credentials, which you can do by following the [Github API Configuration](#github-api-configuration) section.
33
+
12. Enable Prettier in your text editor by following [this guide](https://prettier.io/docs/en/editors.html).
34
+
13.`$ npm start`
35
+
14. Navigate to [http://localhost:8000](http://localhost:8000) in your browser
36
+
15. Install the [React Developer Tools](https://chrome.google.com/webstore/detail/react-developer-tools/fmkadmapgofadopljbjfkapdkoienihi?hl=en)
37
+
16. Open and close the Redux DevTools using `ctrl+h`, and move them with `ctrl+w`
36
38
37
39
## Docker Installation
38
40
@@ -50,6 +52,8 @@ Note that this takes up a significant amount of space on your machine. Make sure
6. (Optional) Update `.env` with necessary keys to enable certain app behaviors, i.e. add Github ID and Github Secret if you want to be able to log in with Github.
55
+
* See the [GitHub API Configuration](#github-api-configuration) section for information on how to authenticate with Github.
56
+
* See the [S3 Bucket Configuration](#s3-bucket-configuration) section for information on how to set up an S3 bucket
53
57
7.`$ docker-compose -f docker-compose-development.yml run --rm app npm run fetch-examples` - note that you need to configure your GitHub Credentials, which you can do by following the [Github API Configuration](#github-api-configuration) section.
54
58
8. Enable Prettier in your text editor by following [this guide](https://prettier.io/docs/en/editors.html).
55
59
@@ -68,22 +72,9 @@ If you don't have the full server environment running, you can launch a one-off
68
72
69
73
## S3 Bucket Configuration
70
74
71
-
Note that this is optional unless you are working on the part of the application that allows a user to upload images, videos, etc. Please refer to the following [gist](https://gist.github.com/catarak/70c9301f0fd1ac2d6b58de03f61997e3) to set up an S3 bucket to be used with this project.
75
+
See [this configuration guide](./s3_configuration.md) for information about how to configure your own S3 bucket. These instructions were adapted from [this gist](https://gist.github.com/catarak/70c9301f0fd1ac2d6b58de03f61997e3).
72
76
73
-
If your S3 bucket is in the US East (N Virginia) region (us-east-1), you'll
74
-
need to set a custom URL base for it, because it does not follow the standard
75
-
naming pattern as the rest of the regions. Instead, add the following to your
76
-
environment/.env file, changing `BUCKET_NAME` to your bucket name. This is necessary because this override is currently treated as the full path to the bucket rather than as a proper base URL:
Note that this is optional unless you are working on the part of the application that allows a user to upload images, videos, etc.
87
78
88
79
## GitHub API Configuration
89
80
@@ -94,9 +85,15 @@ In this application, GitHub credentials are used for:
94
85
95
86
If you are working on a part of the application that requires one of the above uses, then you will need to get GitHub API credentials.
96
87
97
-
When you go to the Developer settings in your GitHub account, you will see that you can create two types of Apps: `GitHub Apps` and `OAuth Apps` ([differences between GitHub Apps and OAuth Apps](https://docs.github.com/en/free-pro-team@latest/developers/apps/differences-between-github-apps-and-oauth-apps)). This project requires you to make an `OAuth App`. After clicking on "New OAuth App", you will need to fill in the following fields:
88
+
When you go to the [Developer settings](https://github.com/settings/developers) in your GitHub account, you will see that you can create two types of Apps: `GitHub Apps` and `OAuth Apps` ([differences between GitHub Apps and OAuth Apps](https://docs.github.com/en/free-pro-team@latest/developers/apps/differences-between-github-apps-and-oauth-apps)). This project requires you to make an `OAuth App`. After clicking on "New OAuth App", you will need to fill in the following fields:
4. Uncheck "Block all public access" under "Block public access (bucket settings)".
43
+
5. Under "Object Ownership", check "ACLs enabled" and set "Object Ownership" to "Object writer"
44
+
6. Locate your AWS key and Secret Key. You can find this in the top AWS navigation under your name -> Security Credentials.
45
+
7. Update the following lines to your .env file:
46
+
```
47
+
AWS_ACCESS_KEY={AWS_ACCESS_KEY}
48
+
AWS_REGION={S3_BUCKET_REGION}
49
+
AWS_SECRET_KEY={AWS_SECRET_KEY}
50
+
S3_BUCKET={S3_BUCKET_NAME}
51
+
```
52
+
53
+
If your S3 bucket is in the US East (N Virginia) region (us-east-1), you'll
54
+
need to set a custom URL base for it, because it does not follow the standard
55
+
naming pattern as the rest of the regions. Instead, add the following to your
56
+
environment/.env file, changing `BUCKET_NAME` to your bucket name. This is necessary because this override is currently treated as the full path to the bucket rather than as a proper base URL:
If you've configured your S3 bucket and DNS records to use a custom domain
60
+
name, you can also set it using this variable. I.e.:
61
+
62
+
`S3_BUCKET_URL_BASE=https://files.mydomain.com`
63
+
64
+
For more information on using a custom domain, see [this documentation link](http://docs.aws.amazon.com/AmazonS3/latest/dev/VirtualHosting.html#VirtualHostingCustomURLs).
0 commit comments