Skip to content

Commit

Permalink
feat: GitHub Actions (#687)
Browse files Browse the repository at this point in the history
* feat: GitHub Actions

* fix: templates styling

* fix: deployment environment urls

* fix: project name in README

* fix: Dockerfile bundle install and secrets

* fix: passing secret to docker build

* fix: add semicolons

* fix: secret casing

* fix: remove semicolon

* feat(Dockerfile): allow RAILS_MASTER_KEY to still be set as build arg

* chore(Dockerfile): final reformatting

* feat: get sourcemaps from image and upload to Sentry

* fix: set Sentry release in Rails

* fix: set Sentry release for js

* fix: single quote lint errors

* fix: use reusable workflows from this project instead

* fix: use whitespace character in regex

* revert: Banana -> AMBER
  • Loading branch information
guidojw authored Mar 13, 2022
1 parent 15c6fcf commit 292da31
Show file tree
Hide file tree
Showing 19 changed files with 604 additions and 133 deletions.
63 changes: 0 additions & 63 deletions .buildkite/pipeline.yml

This file was deleted.

9 changes: 0 additions & 9 deletions .buildkite/release.sh

This file was deleted.

9 changes: 0 additions & 9 deletions .buildkite/sentry.sh

This file was deleted.

8 changes: 0 additions & 8 deletions .buildkite/slack.sh

This file was deleted.

13 changes: 13 additions & 0 deletions .github/issue_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
### How to reproduce

1. ...

### Expected behaviour

Explain what should happen.

### Current behaviour

Explain what currently happens.

*Optionally add some screenshots*
22 changes: 22 additions & 0 deletions .github/problem-matchers/eslint-stylish.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"problemMatcher": [
{
"owner": "eslint-stylish",
"pattern": [
{
"regexp": "^/opt/app/([^\\s].*)$",
"file": 1
},
{
"regexp": "^\\s+(\\d+):(\\d+)\\s+(error|warning|info)\\s+(.*)\\s\\s+(.*)$",
"line": 1,
"column": 2,
"severity": 3,
"message": 4,
"code": 5,
"loop": true
}
]
}
]
}
16 changes: 16 additions & 0 deletions .github/problem-matchers/rspec.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"problemMatcher": [
{
"owner": "rspec",
"severity": "error",
"pattern": [
{
"regexp": "^rspec\\s\\.\/(.*):(.*)\\s#\\s(.*)$",
"file": 1,
"line": 2,
"message": 3
}
]
}
]
}
32 changes: 32 additions & 0 deletions .github/problem-matchers/rubocop.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"problemMatcher": [
{
"owner": "rubocop-error",
"severity": "error",
"pattern": [
{
"regexp": "^(.+):(\\d+):(\\d+):\\sC:\\s((.+):\\s.+)$",
"file": 1,
"line": 2,
"column": 3,
"message": 4,
"code": 5
}
]
},
{
"owner": "rubocop-warning",
"severity": "warning",
"pattern": [
{
"regexp": "^(.+):(\\d+):(\\d+):\\sW:\\s((.+):\\s.+)$",
"file": 1,
"line": 2,
"column": 3,
"message": 4,
"code": 5
}
]
}
]
}
12 changes: 12 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
### Checklist

- [ ] Merged database migrations into 1 database migration.
- [ ] Tested database migrations from `origin/staging` (`git checkout staging ; git pull ; bundle exec rails db:reset ; git checkout BRANCH ; bundle exec rails db:migrate`).

### Summary

Shortly summarize the changes in this pull request. Does it concern changes in the UI, add some screenshots. Are there related issues solved? Please, mention them (with 'fixes #xyz', see https://github.com/blog/1506-closing-issues-via-pull-requests), so they can be resolved automatically when merging this pull request.

### Other information

If there is some other relevant and important information for this pull request, mention it here. For example, related pull requests or newly introduced conventions, packages or other dependencies.
24 changes: 24 additions & 0 deletions .github/workflows/cleanup-registry.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Cleanup Registry

on:
schedule:
- cron: '0 0 * * 1' # https://crontab.guru/#0_0_*_*_1
workflow_dispatch:

env:
IMAGE_NAMES: sofia

jobs:
cleanup:
name: Cleanup
runs-on: ubuntu-latest
steps:
- name: Delete old versions
uses: snok/container-retention-policy@81ba73785bb8207a451a0de928aa6a3c57d6fd77 # tag=v1.4.0
with:
image-names: ${{ env.IMAGE_NAMES }}
cut-off: 2 days ago UTC
account-type: org
org-name: ${{ github.repository_owner }}
skip-tags: latest,staging
token: ${{ secrets.PAT }}
Loading

0 comments on commit 292da31

Please sign in to comment.