-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0c04e00
commit 2c8c47f
Showing
143 changed files
with
6,459 additions
and
156 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
name: Bug report | ||
description: File a bug report | ||
labels: ["bug", "triage"] | ||
projects: ["navapbc/4"] | ||
body: | ||
- type: markdown | ||
attributes: | ||
value: | | ||
Thanks for taking the time to fill out this bug report! | ||
- type: textarea | ||
attributes: | ||
label: What happened? | ||
description: Also tell us, what did you expect to happen? | ||
placeholder: Tell us what you see! | ||
validations: | ||
required: true | ||
- type: textarea | ||
attributes: | ||
label: Steps to reproduce | ||
description: Share the steps or a link to a repository we can use to reproduce the problem. | ||
- type: dropdown | ||
id: browsers | ||
attributes: | ||
label: What browsers are you seeing the problem on? | ||
multiple: true | ||
options: | ||
- Not applicable | ||
- Firefox | ||
- Chrome | ||
- Safari | ||
- Microsoft Edge | ||
- type: textarea | ||
id: logs | ||
attributes: | ||
label: Relevant log output | ||
description: Please copy and paste any relevant log output. This will be automatically formatted into code, so no need for backticks. | ||
render: shell |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
name: Feature request | ||
description: Suggest an idea for this project | ||
labels: ["triage", "feature"] | ||
projects: ["navapbc/4"] | ||
body: | ||
- type: textarea | ||
attributes: | ||
label: Describe the problem and the solution you'd like | ||
description: A clear and concise description of what the problem is and what you want to happen. | ||
value: | | ||
**Is your feature request related to a problem? Please describe.** | ||
<!-- A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] --> | ||
**Describe the solution you'd like** | ||
<!-- A clear and concise description of what you want to happen. --> | ||
**Describe alternatives you've considered** | ||
<!-- A clear and concise description of any alternative solutions or features you've considered. --> | ||
- type: textarea | ||
attributes: | ||
label: Additional context | ||
description: Add any other context or screenshots about the feature request here. | ||
- type: dropdown | ||
attributes: | ||
label: Priority | ||
description: How impactful would this be for your project? | ||
multiple: false | ||
options: | ||
- "My project needs this now" | ||
- "I anticipate needing this soon" | ||
- "Nice to have" | ||
- "Just want to discuss" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
name: Task | ||
description: Create a task for the team | ||
projects: ["navapbc/4"] | ||
body: | ||
- type: textarea | ||
attributes: | ||
label: What's the task? | ||
validations: | ||
required: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: CI app-rails | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- app-rails/** | ||
- .github/workflows/ci-app-rails.yml | ||
pull_request: | ||
paths: | ||
- app-rails/** | ||
- .github/workflows/ci-app-rails.yml | ||
|
||
defaults: | ||
run: | ||
working-directory: ./app-rails | ||
|
||
jobs: | ||
# As an enhancement, it is possible to share the built docker image and share | ||
# it across jobs as described in: | ||
# https://docs.github.com/en/actions/using-workflows/storing-workflow-data-as-artifacts#passing-data-between-jobs-in-a-workflow | ||
lint: | ||
name: Lint | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
# https://github.com/docker/compose/issues/1973 | ||
- name: Create required env files | ||
working-directory: ./ | ||
run: | | ||
touch ./app-rails/.env | ||
- run: make lint | ||
|
||
test: | ||
name: Test | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- run: make init-container | ||
- run: make precompile-assets | ||
|
||
- name: Start tests | ||
run: make test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,72 @@ | ||
# template-application-rails | ||
Ruby on Rails with USWDS template, including CI/CD, for teams building web applications | ||
# Template Ruby on Rails application | ||
|
||
This is a template repository for a Ruby on Rails application. | ||
|
||
See [`navapbc/platform`](https://github.com/navapbc/platform) for other template repos. | ||
|
||
## Features | ||
|
||
- [U.S. Web Design System](https://designsystem.digital.gov/) for themeable styling and a set of common components | ||
- Integration with AWS services, including: | ||
- Database integration with AWS RDS Postgresql using UUIDs | ||
- Active Storage configuration with AWS S3 | ||
- Action Mailer configuration with AWS SES | ||
- Authentication with [devise](https://github.com/heartcombo/devise) and AWS Cognito | ||
- Internationalization (i18n) | ||
- Authorization using [pundit](https://github.com/varvet/pundit) | ||
- Linting and code formatting using [rubocop](https://rubocop.org/) | ||
- Testing using [rspec](https://rspec.info) | ||
|
||
<img width="1023" alt="CleanShot 2024-05-22 at 16 35 53@2x" src="https://github.com/navapbc/template-application-rails/assets/67701/fb291a98-7dfa-429e-91e2-30beacf58b9e"> | ||
|
||
## Repo structure | ||
|
||
```text | ||
├── .github # GitHub workflows and repo templates | ||
├── docs # Project docs and decision records | ||
├── app-rails # Web application | ||
├── template-only-bin # Scripts for managing this template; not copied into your project | ||
├── template-only-docs # Documentation for this template; not copied into your project | ||
``` | ||
|
||
## Installation | ||
|
||
To get started using the template application on your project: | ||
|
||
1. Run the [download and install script](./template-only-bin/download-and-install-template.sh) in your project's root directory. | ||
|
||
```bash | ||
curl https://raw.githubusercontent.com/navapbc/template-application-rails/main/template-only-bin/download-and-install-template.sh | bash -s | ||
``` | ||
|
||
This script will: | ||
|
||
1. Clone the template repository | ||
2. Copy the template files into your project directory | ||
3. Remove any files specific to the template repository, like this README. | ||
|
||
You can optionally pass in a branch, commit hash, or release that you want to install. For example: | ||
|
||
```bash | ||
curl https://raw.githubusercontent.com/navapbc/template-application-rails/main/template-only-bin/download-and-install-template.sh | bash -s -- <commit_hash> | ||
``` | ||
2. [Follow the steps in `app-rails/README.md`](./app-rails/README.md) to set up the application locally. | ||
3. Optional, if using the Platform infrastructure template: [Follow the steps in the `template-infra` README](https://github.com/navapbc/template-infra#installation) to set up the various pieces of your infrastructure. | ||
|
||
## Updates | ||
|
||
If you have previously installed this template and would like to update your project to use a newer version of this application: | ||
|
||
1. Run the [download and install script](./template-only-bin/download-and-install-template.sh) in your project's root directory and pass in the branch, commit hash, or release that you want to update to, followed by the name of your application directory (e.g. `app-rails`). | ||
```bash | ||
curl https://raw.githubusercontent.com/navapbc/template-application-rails/main/template-only-bin/download-and-install-template.sh | bash -s -- <commit_hash> <app_name> | ||
``` | ||
This script will: | ||
1. Clone the template repository | ||
2. Copy the template files into your project directory | ||
3. Remove any files specific to the template repository, like this README. | ||
⚠️ Warning! This will modify existing files. Review all changes carefully after executing the script by running `git diff`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
--require spec_helper |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
require: | ||
- rubocop-rspec | ||
inherit_gem: | ||
pundit: config/rubocop-rspec.yml | ||
rubocop-rails-omakase: rubocop.yml | ||
AllCops: | ||
Exclude: | ||
- lib/templates/**/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.