Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/alassek/attribute-api-example
Example App demonstrating the Rails attribute API
https://github.com/alassek/attribute-api-example
Last synced: 19 days ago
JSON representation
Example App demonstrating the Rails attribute API
- Host: GitHub
- URL: https://github.com/alassek/attribute-api-example
- Owner: alassek
- Created: 2017-08-10T22:32:18.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-08-10T22:33:28.000Z (over 7 years ago)
- Last Synced: 2024-12-01T13:29:13.546Z (25 days ago)
- Language: Ruby
- Size: 37.1 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Rails Attribute API example
This app demonstrates a few interesting possibilities afforded by the new API, including:
1. Default values
2. Encrypted Fields
3. Custom Types## Getting Started
For simplicity, this app uses RSA keys for encryption. You'll need to generate a new keypair,
and convert your public key to PEM format.```
$ ssh-keygen -t rsa -f ~/.ssh/example
$ ssh-keygen -f ~/.ssh/example -e -m pem > ~/.ssh/example.pem
```After that, just the regular startup routine is necessary. This example uses features specific to Postgres.
```
$ bundle
$ rails db:setup
$ rails server
```