Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kevinsqi/climatefuture-client
https://github.com/kevinsqi/climatefuture-client
climate-change
Last synced: 3 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/kevinsqi/climatefuture-client
- Owner: kevinsqi
- Created: 2019-10-30T22:18:07.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2023-01-04T23:48:21.000Z (almost 2 years ago)
- Last Synced: 2024-11-01T04:51:45.878Z (about 2 months ago)
- Topics: climate-change
- Language: JavaScript
- Size: 4.56 MB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 17
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## ClimateFuture client
This is the frontend client that powers [climatefuture.io](https://www.climatefuture.io). The backend code is at [kevinsqi/climatefuture](https://github.com/kevinsqi/climatefuture).
![screenshot of location page](./public/screenshot-orlando.png)
## Setup
First, set up and run the [climatefuture server](https://github.com/kevinsqi/climatefuture) at localhost:3001.
Then, run the client app:
```
yarn install
yarn dev
```Go to http://localhost:3000 to view the app.
**Alternate frontend-only setup:**
If you don't need to modify server code, you can also run `yarn dev:prod-api` to use the prod API instead of running a local API server at localhost:3001.
## Deployment
* Create app: `dokku apps:create climatefuture-client`
* Add dokku remote: `git remote add dokku [email protected]:climatefuture-client`
* Push to dokku: `git push dokku master`
* Add domains:
* Add DNS records to point @ and www to dokku instance
* `dokku domains:add climatefuture-client climatefuture.io www.climatefuture.io`
* Set environment variables: `dokku config:set climatefuture-client GOOGLE_ANALYTICS_TRACKING_ID=`Setting up https with `dokku-letsencrypt` and [this guide](https://medium.com/@pimterry/effortlessly-add-https-to-dokku-with-lets-encrypt-900696366890):
* `dokku config:set --no-restart climatefuture-client DOKKU_LETSENCRYPT_EMAIL=`
* `dokku letsencrypt climatefuture-client`
* `dokku letsencrypt:cron-job --add`
* Verify cron job with `crontab -l -u dokku`Redirect to www:
* Install [dokku-redirect](https://github.com/dokku/dokku-redirect)
* `dokku redirect:set climatefuture-client climatefuture.io www.climatefuture.io`