Skip to content

Commit

Permalink
Add support for render
Browse files Browse the repository at this point in the history
  • Loading branch information
yatish27 committed May 15, 2024
1 parent 30673cf commit 639d330
Show file tree
Hide file tree
Showing 3 changed files with 57 additions and 4 deletions.
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@
- **Deployment**: Supports deployment at [Heroku](https://www.heroku.com/platform) and [Render](https://render.com)


## Getting Started 💻
## Getting Started 🚀


### Requirements
### System Requirements
You will need the following installed to run the application.

- Ruby [3.3.1](.ruby-version)
Expand Down Expand Up @@ -98,6 +98,8 @@ Once you have cloned the repository and have docker installed
- Run `docker-compose up` to start the application.
Since the local code from your host machine is mounted in the docker container, any change made in the code will be directly reflected. You don't need to rebuild you container.

## Deployment

## Testing 🧪
Running all tests
```
Expand All @@ -110,7 +112,7 @@ Running a single test
```

## License 🔑
Shore is released under the MIT License.
Shore is released under the [MIT License](./LICENSE.txt).

## Contributing 🤝
PRs are welcome to repository
PRs are welcome
10 changes: 10 additions & 0 deletions bin/render-build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/usr/bin/env bash
# exit on error
set -o errexit

bundle install
bundle exec rake assets:precompile
bundle exec rake assets:clean

bundle exec rails db:migrate
bundle exec rails db:seed
41 changes: 41 additions & 0 deletions render.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
databases:
- name: database
databaseName: database
user: shore
plan: starter

services:
- type: web
name: web
env: ruby
buildCommand: "./bin/render-build.sh"
startCommand: "bundle exec puma -C config/puma.rb"
envVars:
- key: DATABASE_URL
fromDatabase:
name: database
property: connectionString
- fromGroup: settings
- type: worker
name: worker
env: ruby
buildCommand: "bundle install && bundle exec rake assets:precompile && bundle exec rake assets:clean"
startCommand: "bundle exec rake solid_queue:start"
envVars:
- key: DATABASE_URL
fromDatabase:
name: database
property: connectionString
- fromGroup: settings

envVarGroups:
- name: settings
envVars:
- key: FONTAWESOME_NPM_AUTH_TOKEN
sync: false
- key: POSTMARK_API_TOKEN
sync: false
- key: HIDE_THINGS
generateValue: true
- key: SECRET_KEY_BASE
generateValue: true

0 comments on commit 639d330

Please sign in to comment.