Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/epomatti/cors
CORS sandbox
https://github.com/epomatti/cors
cors javascript nodejs
Last synced: about 18 hours ago
JSON representation
CORS sandbox
- Host: GitHub
- URL: https://github.com/epomatti/cors
- Owner: epomatti
- License: mit
- Created: 2022-08-05T21:06:46.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-08-18T20:03:11.000Z (about 1 year ago)
- Last Synced: 2023-08-18T20:12:48.500Z (about 1 year ago)
- Topics: cors, javascript, nodejs
- Language: JavaScript
- Homepage:
- Size: 832 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# CORS sandbox
Install dependencies:
```sh
yarn install
```Create the `.env` and setup the CORS configuration:
```sh
# Other options are "express", "express_with_options", and "none"
CORS_MODE="manual"
```Start the server:
```sh
yarn dev
```Check that the service is running:
```sh
curl 'localhost:8080/hello?name=John'
```To run the client `index.html`:
```
npx serve .
```#### AWS S3 WebSite
In case you want to deploy to S3:
```sh
terraform init
terraform apply -auto-approve
```WebSite should be available here:
```
https://bucket-s3-web-56789.s3-website.sa-east-1.amazonaws.com
```