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

feat:Connect iOS Notifications to Grade Published Hook #186

Closed
Closed
Show file tree
Hide file tree
Changes from 8 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .env
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ DB_PORT=3306
APNS_KEY_ID=
APNS_TEAM_ID=
APNS_P8_FILE_PATH=/secrets/AuthKey_XXXX.p8
API_KEY=secret_api_key
IOS_EXAMS_HOOK_CALLBACK_URL=http://backend:50051/v1/ios/exams/new

ENVIRONMENT=dev

Expand Down
10 changes: 7 additions & 3 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,22 +13,26 @@ services:
- APNS_KEY_ID=${APNS_KEY_ID}
- APNS_TEAM_ID=${APNS_TEAM_ID}
- APNS_P8_FILE_PATH=${APNS_P8_FILE_PATH}
- API_KEY=${API_KEY}
Antonwy marked this conversation as resolved.
Show resolved Hide resolved
- IOS_EXAMS_HOOK_CALLBACK_URL=${IOS_EXAMS_HOOK_CALLBACK_URL}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please also add any additional variables here

and tell me offline what should be written there ^^

volumes:
- ./apns_auth_key.p8:${APNS_P8_FILE_PATH}
depends_on:
- db

db:
container_name: campus-db
image: bitnami/mariadb:10
image: mariadb:latest
Antonwy marked this conversation as resolved.
Show resolved Hide resolved
ports:
- ${DB_PORT:-3306}:3306
environment:
- MARIADB_ROOT_PASSWORD=${DB_ROOT_PASSWORD}
- MARIADB_DATABASE=${DB_NAME}
volumes:
- campus-db-data:/bitnami/mariadb
- ./deployment/charts/backend/files/source-schema.sql:/docker-entrypoint-startdb.d/schema.sql
- campus-db-data:/var/lib/mysql
- ./source-schema.sql:/entrypoint/schema.sql
# Execute in container to init with schema:
# mysql --user=root --password=secret_root_password campus_db < /entrypoint/schema.sql
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this intentional?
This means that the source-shema we use as a source of truth is not used anymore or am I understanding this incorrectly?

Suggested change
- campus-db-data:/var/lib/mysql
- ./source-schema.sql:/entrypoint/schema.sql
# Execute in container to init with schema:
# mysql --user=root --password=secret_root_password campus_db < /entrypoint/schema.sql
- campus-db-data:/bitnami/mariadb
- ./deployment/charts/backend/files/source-schema.sql:/docker-entrypoint-startdb.d/schema.sql

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Screenshot 2023-09-17 at 18 55 25@2x

Somehow does the bitnami image not work on my local machine. Did you encounter something similar?

Copy link
Member

@CommanderStorm CommanderStorm Sep 17, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, I did not.

  • What is your platform?
  • Does deleting the docker volume and re-running fix this issue?
    My assumption is that said directory is owned by root on your machine. This won't work, as the container is a non-root container.


volumes:
campus-db-data:
Loading