Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v1.0 #831

Closed
wants to merge 1,974 commits into from
Closed

v1.0 #831

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
1974 commits
Select commit Hold shift + click to select a range
f7c53c5
Fix issue where user was redirected when not signed in on create-acco…
Portals May 4, 2020
94191de
Add user agreeement dialog to create-account
Portals May 4, 2020
734cb38
Update RDC
Portals May 4, 2020
b75518e
Move Groups and Users link from AdminOptions to UsersOptions
Portals May 4, 2020
17c4382
Minor changes, some translations added
Portals May 4, 2020
e6b4c4d
Minor frontend changes
Portals May 4, 2020
e2a6ffc
EditPassword translations
Portals May 4, 2020
c7aaca8
Add delete dialog text to Groups
Portals May 4, 2020
22c8692
Redirect back when password has been changed by admin
Portals May 4, 2020
44eb393
Merge branch 'dev' into dev-temp
Portals May 4, 2020
74d3c43
Merge pull request #683 from cthit/dev-temp
Portals May 4, 2020
6590b63
Resolve issue with useHistoryGoBackOnBack
Portals May 5, 2020
ca3b227
v1.0.1
Portals May 5, 2020
eaffd67
User agreements added
Sponken May 5, 2020
3248b5a
Fix typos and small suggestion
Sponken May 5, 2020
c55b017
Readability approved
Sponken May 5, 2020
2af002c
Further readability changes
Sponken May 5, 2020
74bb4b9
Merge pull request #701 from cthit/user-agreement
Sponken May 5, 2020
e8ce325
resolve some problems with chalmers.it integration
Gurrit May 6, 2020
33e7276
License under AGPL
hulthe May 6, 2020
ff3e2e9
Add ENV for PRODUCTION in application.production.yml
Portals May 7, 2020
ac9fb3e
Add setupProxy, to be able to change the proxy via ENV
Portals May 7, 2020
5258420
Resolve checkstyle
Portals May 7, 2020
99f752e
Merge pull request #710 from cthit/fix/docker-usage
Portals May 7, 2020
ddb16d2
Fixed typo
Deltaphish May 16, 2020
d526ca0
Merge pull request #728 from cthit/make-gamma-better
Deltaphish May 16, 2020
042b507
Only allows post to be deleted if they are not used
molleer May 24, 2020
6c23c2c
Removed changes from Membership
molleer May 24, 2020
52b03ab
Hiding delete button if post is used
molleer May 24, 2020
2cea068
Merge branch 'dev' into license
Gurrit Jun 3, 2020
b1bcc7e
Merge pull request #706 from hulthe/license
Gurrit Jun 3, 2020
8b52223
create 404 error page
Gurrit Jun 3, 2020
4cc20f3
Add basic 500 error page
Gurrit Jun 3, 2020
8ce8456
Improve 404 page
Gurrit Jun 3, 2020
a9ff583
Add a 422 error response
Gurrit Jun 3, 2020
025d55b
Fix titles of /error
Gurrit Jun 3, 2020
a38ea97
format all HTML files
Gurrit Jun 3, 2020
65e08f7
Add a default error for non-mapped error messages
Gurrit Jun 3, 2020
cba7aa2
Merge branch 'dev' into feat/better_backend_error_messages
Gurrit Jun 3, 2020
b5b74e8
resolve PMD and checkstyle complataints
Gurrit Jun 3, 2020
3c0b2af
Merge branch 'feat/better_backend_error_messages' of https://github.c…
Gurrit Jun 3, 2020
994c452
upgrade PMD and resolve complatiants due to this
Gurrit Jun 3, 2020
905ee86
fix development dockerfile failing builds
Gurrit Jun 3, 2020
5a34742
provide a docker-compose file with already prepared backend
Gurrit Jun 3, 2020
4c8aba8
Make prod docker-compose easier to test
Gurrit Jun 4, 2020
bdd09a4
Change background color of error messages
Gurrit Jun 9, 2020
4c5e27f
resolve PMD test issue
Gurrit Jun 9, 2020
82a0a1a
Merge pull request #733 from cthit/feat/better_backend_error_messages
Gurrit Jun 9, 2020
b7c64b5
Merge branch 'dev' into fix/backend_docker
Gurrit Jun 9, 2020
e47172f
update README
Gurrit Jun 9, 2020
2c62789
Merge remote-tracking branch 'origin/fix/backend_docker' into fix/bac…
Gurrit Jun 9, 2020
d7d61d1
Merge pull request #735 from cthit/fix/backend_docker
Gurrit Jun 9, 2020
0da9775
add a test for logging in using email
Gurrit Jun 9, 2020
5e06e91
improve error logging in development mode
Gurrit Jun 9, 2020
e188516
should resolve the problem with email login not working
Gurrit Jun 9, 2020
fcb65ff
Merge branch 'dev' into fix/email_login
Gurrit Jun 9, 2020
19e5935
Resolve issue when mock.json wasn't accessible in production
Portals Jun 19, 2020
b4d80cb
Add reverse proxy to prod.docker-compose.yml
Portals Jun 19, 2020
2275c04
Specify image tag between latest and development for frontend
Portals Jun 19, 2020
8b932cc
Add reminder to use docker-compose down
Portals Jun 19, 2020
19d228d
Remove unused console.log
Portals Jun 19, 2020
1b06cad
Add Gurr and Portals as codeowners, resolve #729
Portals Jun 20, 2020
40cc59a
Set min width for cid input form to 300px
Portals Jun 20, 2020
019b8e9
Merge pull request #736 from cthit/fix/email_login
Gurrit Jun 20, 2020
f98a499
Merge branch 'dev' into fix/712
Gurrit Jun 20, 2020
5ba6dcb
Merge pull request #737 from cthit/fix/712
Gurrit Jun 20, 2020
54c101e
Merge branch 'dev' into fix/738
Gurrit Jun 20, 2020
328440d
Merge pull request #739 from cthit/fix/738
Gurrit Jun 20, 2020
36a61f4
Merge branch 'dev' into fix/729-code-owners
Gurrit Jun 20, 2020
f7e4001
Merge pull request #740 from cthit/fix/729-code-owners
Gurrit Jun 20, 2020
68fc886
Merge branch 'dev' into fix/714-create-account-mobile
Gurrit Jun 20, 2020
4c62ffc
Merge pull request #741 from cthit/fix/714-create-account-mobile
Gurrit Jun 20, 2020
defeb40
Merge branch 'dev' into delete-post
Portals Jun 20, 2020
baf3858
Resolve checkstyle and pmd issues
Portals Jun 20, 2020
def1ee0
Merge pull request #730 from cthit/delete-post
Gurrit Jun 21, 2020
760f853
Resolve #704, add user avatar in users read one view
Portals Jun 22, 2020
ba28dfc
Resolve #689, add swedish search translations
Portals Jun 22, 2020
809e194
Resolve #705, ignore link if id is null
Portals Jun 22, 2020
fe0a9b5
Resolve #725, add loading wheel to GDPR use-case
Portals Jun 22, 2020
7a8fd2d
Replace text with search translations
Portals Jun 22, 2020
b717fa4
hmmm Remove odd console.log
Portals Jun 22, 2020
b75e686
Upgrade rdc to 1.0.2
Portals Jun 25, 2020
9dd5051
Merge pull request #745 from cthit/minor-frontend-issues
Portals Jun 25, 2020
734161d
Merge pull request #746 from cthit/maintenance/rdc-1.0.2
Portals Jun 25, 2020
73c9be4
disable session timeout
Gurrit Jun 27, 2020
be72ef4
that last commit used a deprecated tag
Gurrit Jun 27, 2020
7ec9b5a
Merge pull request #748 from cthit/fix/disable_session_timeout
Gurrit Jun 27, 2020
5d2efa1
Add clarification that you'll need to specify compose file
Portals Jun 30, 2020
e3ed617
Rename ShowSuperGroups to ShowSubGroups
Portals Jun 30, 2020
bac602a
Add possibility to change emailPrefix for a post
Portals Jun 30, 2020
8e05bef
Displays post mail if group is active and emailPrefix for a post is n…
Portals Jun 30, 2020
7ab55b6
Resolve #715, correct validation amongst other smaller things
Portals Jul 1, 2020
75603e7
Set default backend url to gamma.chalmers.it/api
Portals Jul 3, 2020
cceb8ae
Add custom authorize page for OAuth2
Portals Jun 20, 2020
60db4ec
Add autoApprove switch in frontend and logic in backend
Portals Jun 20, 2020
cd727ee
Add custom approvalStore
Portals Jul 4, 2020
b0be54d
Merge branch 'dev' into fix/715-selecting-posts
Gurrit Jul 6, 2020
28bda5d
Merge pull request #753 from cthit/fix/715-selecting-posts
Gurrit Jul 6, 2020
f65a92c
Show users that approved a client, add hidden use-case to see what a …
Portals Jul 14, 2020
34e5dae
Add /users/{id}/avatar that redirects to a users avatar profile picture
Portals Jul 14, 2020
d4624e8
Add local version of material-components-web js and css versions
Portals Jul 14, 2020
c5d2070
Makes ITUserRestrictedDTO more restricted
Portals Aug 29, 2020
41db5db
Resolve issue where phone number couldn't be edited
Portals Aug 30, 2020
0e53257
Create RestrictedMembershipDTO and use that in relevant responses
Portals Aug 30, 2020
0373b7d
Merge pull request #767 from cthit/fix/read-access
ejohnsson6 Sep 21, 2020
11cec0f
Show the user nick instead of name on home page
hulthe Nov 20, 2020
2cbcce8
Merge pull request #777 from hulthe/fix/show_real_name
ejohnsson6 Nov 23, 2020
cdadf2a
Merge branch 'dev' into feat/721-permanent-avatar-url
Portals Nov 23, 2020
e852f56
Merge branch 'dev' into feat/686
Portals Dec 16, 2020
c84bd44
Update dependencies and gradle
Portals Dec 16, 2020
9e97743
Resolve issues with build.gradle
Portals Dec 16, 2020
3c712d1
mock-client -> mocking
Portals Dec 17, 2020
77a7feb
Resolve test issues with oauth
Portals Dec 17, 2020
7e5e841
Resolve minor pmd and checkstyle issues
Portals Dec 17, 2020
c9c7d3b
Merge pull request #756 from cthit/feat/686
Portals Dec 17, 2020
35780c8
Merge pull request #761 from cthit/fix/726-mcb
Portals Dec 17, 2020
818fe29
Merge pull request #760 from cthit/feat/721-permanent-avatar-url
Portals Dec 17, 2020
51575f0
Remove everything that has to do with website as it's not finished
Portals Dec 23, 2020
8d8c8d3
Started working on moving around stuff
Portals Dec 23, 2020
59539b2
A start
Portals Jan 8, 2021
e82f72e
ITUserFinder
Portals Jan 11, 2021
3033df5
Yses
Portals Jan 12, 2021
bca2825
working...
Portals Jan 23, 2021
49688ca
finalizing structure
Portals Jan 26, 2021
d3698dd
work
Portals Feb 3, 2021
683a29d
more
Portals Feb 6, 2021
3e39199
almost
Portals Feb 11, 2021
2bf5460
compiles
Portals Feb 11, 2021
2b80b73
userid
Portals Feb 19, 2021
7a1d9b6
Use Cid
Portals Feb 19, 2021
46eb196
small
Portals Feb 19, 2021
3a2cc9c
PostId
Portals Feb 20, 2021
9d8b9a0
SuperGroupId and GroupId
Portals Feb 20, 2021
6f6b62a
ApiKeyId and TextId
Portals Feb 20, 2021
36dc43e
clientid clientsecret and more
Portals Feb 21, 2021
070ca25
checkpoint
Portals Feb 24, 2021
33beb02
asdf
Portals Feb 26, 2021
d0c1564
Update login error message text.
ViddeM Mar 18, 2021
09bcf63
Merge pull request #801 from ViddeM/patch-1
Portals Mar 21, 2021
6301f9c
Lots of moving. Remove phone. Update API.
Portals Mar 27, 2021
29771bb
Merge remote-tracking branch 'origin/refactor' into refactor
Portals Mar 27, 2021
bed1f4a
lmao sorry
Portals Mar 28, 2021
7b2ab47
more
Portals Apr 2, 2021
39cf376
Enable CSRF
Portals Apr 3, 2021
89986da
Progress
Portals Apr 4, 2021
d614e2c
Start of testing
Portals Apr 7, 2021
4f0aa76
Create codeql-analysis.yml
Portals Apr 8, 2021
3b8a02c
Create gradle.yml
Portals Apr 8, 2021
ebde3a2
progress
Portals Apr 9, 2021
e1fb629
records everywhere
Portals May 5, 2021
40e550f
internal and api
Portals May 5, 2021
210068a
api stuff
Portals May 6, 2021
e8fdcfd
frontend and more backend
Portals May 14, 2021
deb4e18
authorities
Portals May 16, 2021
ac8b430
correct equals
Portals May 16, 2021
65d73ed
bootstrap and movement
Portals May 19, 2021
38b35cf
start of cors rewrite
Portals May 20, 2021
c18608e
Work on domain
Portals May 24, 2021
957caee
more bootstrap
Portals May 24, 2021
bf24e9f
fix issue with name
Portals May 29, 2021
cd80ef8
Remove finders and merge them with services
Portals Jun 3, 2021
515116a
fixes
Portals Jun 3, 2021
c2edc87
smaller stuff
Portals Jun 4, 2021
a357413
upgrade frontend deps and settings
Portals Jun 4, 2021
e16b522
start on work for frontend
Portals Jun 4, 2021
6c00cbf
domain movement
Portals Jun 7, 2021
7cc379d
Move around stuff in internal folder
Portals Jun 7, 2021
f7b0aa7
continue
Portals Jun 8, 2021
ca77be2
clients and authorities
Portals Jun 9, 2021
4424d9c
work
Portals Jun 10, 2021
220e58d
super group types
Portals Jun 10, 2021
e9ef53f
reset client secret and redirect on delete, more cascade also
Portals Jun 10, 2021
ea9e767
domain stuff
Portals Jun 15, 2021
f6abda1
images and stuff
Portals Jun 16, 2021
35fb6b0
be able to reset api key
Portals Jun 16, 2021
70869a5
Enforce user agreement
Portals Jun 17, 2021
5f64651
work
Portals Jun 19, 2021
a23968c
Fix AppSettings compiler errors
Portals Jun 19, 2021
acdecbf
things
Portals Jun 24, 2021
3609690
Started moving towards a ports and adapters architecture
Portals Jun 24, 2021
7f113cb
ports and adapters part 1
Portals Jun 27, 2021
ebeaa0d
i have a plan
Portals Jul 13, 2021
d6017e5
about that plan...
Portals Jul 14, 2021
3a18cf3
it's a mess
Portals Jul 21, 2021
d09645c
moar
Portals Jul 22, 2021
bf1f514
progress
Portals Sep 8, 2021
a5db832
yes
Portals Sep 21, 2021
54578b4
progress
Portals Sep 22, 2021
4a50d7e
lots of work in api web
Portals Sep 26, 2021
189bf62
movement
Portals Sep 27, 2021
5b607a0
asdf
Portals Sep 28, 2021
5093bd4
images, members, version start
Portals Oct 5, 2021
35eddb5
stuff
Portals Oct 7, 2021
4e0ed64
more of going around fixing the frontend
Portals Oct 7, 2021
579b921
more
Portals Oct 9, 2021
8745835
web client basically done, started working on new oauth2
Portals Oct 11, 2021
c2c5807
spring-authorization-server is being used
Portals Nov 6, 2021
64f145d
more
Portals Nov 17, 2021
69f7369
Got userinfo oidc
Portals Dec 5, 2021
9087358
more
Portals Dec 5, 2021
91e86ce
updates
Portals Dec 17, 2021
21e18d1
Custom consent
Portals Dec 18, 2021
cc3028c
more
Portals Dec 18, 2021
fe1dede
tests and accessmanager
Portals Dec 19, 2021
3a7dc7a
info api settings
Portals Dec 19, 2021
aa50f53
no more email, stuff
Portals Dec 20, 2021
becdb8e
Start of AuthorityLevelFacadeTest
Portals Dec 22, 2021
3c9ccc0
More tests, spring data tests, persistable
Portals Dec 24, 2021
a04fe1e
More tests
Portals Dec 28, 2021
a887a8b
tests
Portals Dec 29, 2021
ad24039
testcontainer, more tests, versions, and stuff
Portals Dec 30, 2021
582f0f7
more tests and responses to tests
Portals Dec 31, 2021
537fd82
more tests
Portals Jan 1, 2022
7a103d9
Rewrite of User domain object. Only signed in and admin can access Us…
Portals Jan 1, 2022
fe224fb
Move language from extended to normal
Portals Jan 1, 2022
5d59b4f
Testing with Gradle?
Portals Jan 1, 2022
7546fe3
Correct folder?
Portals Jan 1, 2022
4c15799
Working directory?
Portals Jan 1, 2022
c44301e
Did it work? I need to test this
Portals Jan 1, 2022
527acc6
stuff
Portals Feb 12, 2022
fdf574c
Delete SingleImmutableEntity
Portals Feb 12, 2022
8ea4a3e
Add UserActivationEntityIntegrationTests
Portals Feb 15, 2022
c2944a1
more tests
Portals Feb 23, 2022
ae4bb1c
Yes
Portals Feb 25, 2022
17d7cc2
UPgrade deps and movement towards new security logic
Portals Mar 17, 2022
aaad276
:brain:
Portals Mar 20, 2022
8929b46
Use User from Spring Security :brain:
Portals Mar 20, 2022
4bb6ce9
Both api tests and integration tests can now live together
Portals Apr 3, 2022
679fb3f
??
Portals Aug 19, 2022
ca64320
Forward again
Portals Aug 19, 2022
7d9bd75
more
Portals Aug 20, 2022
535f51c
More fixes on auth and tests
Portals Aug 20, 2022
38659c1
Minor Update
Portals Jan 31, 2023
893d4f1
Update
Portals Feb 7, 2023
ef75fe6
Update
Portals Feb 10, 2023
b853495
Update
Portals Feb 10, 2023
093e628
Update
Portals Feb 11, 2023
5421d4b
Update
Portals May 21, 2023
d062526
Update
Portals May 22, 2023
7c0893c
Update
Portals Aug 24, 2023
e43abbb
Update
Portals Aug 24, 2023
b7226fa
Update
Portals Dec 4, 2023
baac593
Update
Portals Dec 10, 2023
fcd545e
Update
Portals Dec 10, 2023
b67d1e5
Update
Portals Dec 11, 2023
f7991ed
Update
Portals Dec 11, 2023
7275558
Update
Portals Dec 11, 2023
9d07a37
Update
Portals Dec 12, 2023
7472dff
Update
Portals Dec 12, 2023
e078fb4
Update
Portals Dec 12, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions .gitconfig.save
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

1 change: 1 addition & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @portals
30 changes: 30 additions & 0 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# This workflow will build a Java project with Gradle
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle

name: Java CI with Gradle

on:
pull_request:
branches: [main]

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up JDK 19
uses: actions/setup-java@v2
with:
java-version: "19"
- name: Validate Gradle wrapper
uses: gradle/wrapper-validation-action@e6e38bacfdf1a337459f332974bb2327a31aaf4b
- name: Testing
working-directory: ./backend
run: ./gradlew test
- name: Cleanup Gradle Cache
# Remove some files from the Gradle cache, so they aren't cached by GitHub Actions.
# Restoring these files from a GitHub Actions cache might cause problems for future builds.
run: |
rm -f ~/.gradle/caches/modules-2/modules-2.lock
rm -f ~/.gradle/caches/modules-2/gc.properties
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
yarn-error.log
frontend/node_modules/
.idea/*
.DS-Store
1 change: 1 addition & 0 deletions .mailmap
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Theodor Angergård <[email protected]> <[email protected]>
22 changes: 22 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
language: java

jdk:
- oraclejdk11

before_script:
- cd backend

script:
- ./gradlew build --console 'plain' -s

before_cache:
- rm -f $HOME/.gradle/caches/modules-2/modules-2.lock
- rm -fr $HOME/.gradle/caches/*/plugin-resolution/

cache:
directories:
- $HOME/.gradle/caches/
- $HOME/.gradle/wrapper/

notifications:
email: false
661 changes: 661 additions & 0 deletions LICENSE

Large diffs are not rendered by default.

38 changes: 37 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,37 @@
# Gamma
# Gamma

[![Build Status](https://travis-ci.com/cthit/Gamma.svg?branch=develop)](https://travis-ci.com/cthit/Gamma)

# Gamma is Chalmers IT section account system

Gamma is licensed under the GNU AGPL, see `LICENSE`.

---

## More information about Gamma can be found on the [Wiki](https://github.com/cthit/Gamma/wiki)

## Build setup

### For production

it's real easy. Just replace the environment variables with suitable value (see wiki)
and run:

`docker-compose -f prod.docker-compose.yml up --build`

Depending on your build system, things might be different, and a proxy is probably needed for a real production version of Gamma.

### Development

run

`docker-compose up --build` to build the frontend, backend, database, databasemonitoring, and all microservices that's needed for Gamma.

If developing on the backend, we recomend not running the backend in the docker-compose file. There is a docker-compose file that sets up all microservice but the backend, to use this run: `docker-compose -f no_backend.docker-compose.ym up --build`
then you will need to start the server, this is done by running the Java code in the backend, and is probably best done through an IDE.

You'll need to run `docker-compose down` / `docker-compose -f no_backed.docker-compose.yml down` if you want to try the production build. Same if you're going from production to development.

## API Documentation

The API documentation is auto-generated by [Swagger](https://swagger.io/) and can be found under http://localhost:8081/api/swagger-ui.html while the application is running.
Empty file added backend/.dcignore
Empty file.
33 changes: 33 additions & 0 deletions backend/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
.gradle/
/build/
!gradle/wrapper/gradle-wrapper.jar
/uploads/

/src/main/resources/secrets.properties

### STS ###
.apt_generated
.classpath
.factorypath
.project
.settings
.springBeans
.sts4-cache

### IntelliJ IDEA ###
.idea
*.iws
*.iml
*.ipr
/out/
.idea/

### NetBeans ###
/nbproject/private/
/build/
/nbbuild/
/dist/
/nbdist/
/.nb-gradle/

secrets.properties
6 changes: 6 additions & 0 deletions backend/.jpb/jpb-settings.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="JpaPluginProjectSettings">
<option name="lastSelectedLanguage" value="Java" />
</component>
</project>
10 changes: 10 additions & 0 deletions backend/.run/GammaApplication.run.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="GammaApplication" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot">
<module name="gamma.main" />
<option name="SPRING_BOOT_MAIN_CLASS" value="it.chalmers.gamma.GammaApplication" />
<option name="ALTERNATIVE_JRE_PATH" />
<method v="2">
<option name="Make" enabled="true" />
</method>
</configuration>
</component>
23 changes: 23 additions & 0 deletions backend/.run/Tests in 'gamma.test'.run.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="Tests in 'gamma.test'" type="GradleRunConfiguration" factoryName="Gradle">
<ExternalSystemSettings>
<option name="executionName" />
<option name="externalProjectPath" value="$PROJECT_DIR$" />
<option name="externalSystemIdString" value="GRADLE" />
<option name="scriptParameters" value="" />
<option name="taskDescriptions">
<list />
</option>
<option name="taskNames">
<list>
<option value=":test" />
</list>
</option>
<option name="vmOptions" />
</ExternalSystemSettings>
<ExternalSystemDebugServerProcess>false</ExternalSystemDebugServerProcess>
<ExternalSystemReattachDebugProcess>true</ExternalSystemReattachDebugProcess>
<DebugAllEnabled>false</DebugAllEnabled>
<method v="2" />
</configuration>
</component>
130 changes: 130 additions & 0 deletions backend/build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,130 @@
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath "org.springframework.boot:spring-boot-gradle-plugin:3.0.1"
}
}

plugins {
id "java"
id "eclipse"
id "application"
id "checkstyle"
id "pmd"
id "nebula.lint" version "16.7.0"
}

apply plugin: "org.springframework.boot"
apply plugin: "io.spring.dependency-management"
group = "it.chalmers"
version = "1.0.0-SNAPSHOT"
sourceCompatibility = 19
mainClassName = "it.chalmers.gamma.GammaApplication"

ext {
springBootVersion = "3.0.4"
springSecurityVersion = "6.0.2"
}

repositories {
mavenCentral()
}

dependencies {
annotationProcessor(
// Used to generate Record Builder classes
"io.soabase.record-builder:record-builder-processor:35",

// Used to generate useful configuration metadata for IDEs
"org.springframework.boot:spring-boot-configuration-processor:${springBootVersion}",
)

implementation(
// Used to generate Record Builder classes
"io.soabase.record-builder:record-builder-core:35",

// Used to handle SQL specific errors
"org.postgresql:postgresql:42.6.0",

// Spring Boot
"org.springframework.boot:spring-boot:${springBootVersion}",
"org.springframework.boot:spring-boot-autoconfigure:${springBootVersion}",
"org.springframework.boot:spring-boot-starter-data-jpa:${springBootVersion}",
"org.springframework.boot:spring-boot-starter-security:${springBootVersion}",
"org.springframework.boot:spring-boot-starter-validation:${springBootVersion}",
"org.springframework.boot:spring-boot-starter-web:${springBootVersion}",

// OAuth2 Server
"org.springframework.security:spring-security-oauth2-authorization-server:1.0.1",

// Spring session
"org.springframework.session:spring-session-core:3.0.0",

// Jackson (JSON)
'com.fasterxml.jackson.core:jackson-core:2.14.2',

// Spring Data
"org.springframework.data:spring-data-jpa:3.0.3",
'org.springframework.data:spring-data-redis:3.0.6'
)

runtimeOnly(
// FLywayDB (Database migration)
"org.flywaydb:flyway-core:9.16.0",

// Spring Boot
"org.springframework.boot:spring-boot-devtools:${springBootVersion}",
"org.springframework.boot:spring-boot-starter-data-redis:${springBootVersion}",
"org.springframework.boot:spring-boot-starter-thymeleaf:${springBootVersion}",
)

testImplementation(
"com.tngtech.archunit:archunit:1.0.0",
"io.rest-assured:json-path:5.3.0",
"io.rest-assured:rest-assured:5.3.0",
"io.rest-assured:xml-path:5.3.0",
"org.flywaydb:flyway-core:9.16.0",
"org.mockito:mockito-inline:5.2.0",
"org.springframework.boot:spring-boot-starter-test:${springBootVersion}",
"org.springframework.security:spring-security-test:6.0.2",
"org.testcontainers:junit-jupiter:1.17.6",
"org.testcontainers:postgresql:1.17.6",
)
}

dependencyManagement {
imports {
mavenBom "org.testcontainers:testcontainers-bom:1.16.3"
}
}

test {
useJUnitPlatform()
}

repositories {
mavenCentral()
}

checkstyle {
toolVersion = "8.11"
ignoreFailures = false
maxWarnings = 0
configFile = project(":").file("config/checkstyle/checkstyle.xml")
configProperties = ["suppressionFile": project(":").file("config/checkstyle/suppressions.xml")]
}

pmd {
toolVersion = "6.21.0"
consoleOutput = false
ignoreFailures = false
ruleSets = []
ruleSetConfig = resources.text.fromFile("./config/pmd/ruleset.xml")
}

// Is not perfect, but gives you an idea of what needs to be changed
//gradleLint {
// rules = ["dependency-parentheses", "archaic-wrapper"]
//}
Loading
Loading