Start on data model changes and API changes for the new repository notification system
This commit is contained in:
parent
06350fb9ae
commit
a84fe0681a
16 changed files with 18557 additions and 18338 deletions
18
initdb.py
18
initdb.py
|
@ -206,8 +206,6 @@ def initialize_database():
|
|||
LogEntryKind.create(name='change_repo_visibility')
|
||||
LogEntryKind.create(name='add_repo_accesstoken')
|
||||
LogEntryKind.create(name='delete_repo_accesstoken')
|
||||
LogEntryKind.create(name='add_repo_webhook')
|
||||
LogEntryKind.create(name='delete_repo_webhook')
|
||||
LogEntryKind.create(name='set_repo_description')
|
||||
|
||||
LogEntryKind.create(name='build_dockerfile')
|
||||
|
@ -231,6 +229,13 @@ def initialize_database():
|
|||
LogEntryKind.create(name='delete_application')
|
||||
LogEntryKind.create(name='reset_application_client_secret')
|
||||
|
||||
# TODO: remove these when webhooks are removed.
|
||||
LogEntryKind.create(name='add_repo_webhook')
|
||||
LogEntryKind.create(name='delete_repo_webhook')
|
||||
|
||||
LogEntryKind.create(name='add_repo_notification')
|
||||
LogEntryKind.create(name='delete_repo_notification')
|
||||
|
||||
NotificationKind.create(name='password_required')
|
||||
NotificationKind.create(name='over_private_usage')
|
||||
NotificationKind.create(name='expiring_license')
|
||||
|
@ -241,6 +246,15 @@ def initialize_database():
|
|||
ImageStorageLocation.create(name='local_eu')
|
||||
ImageStorageLocation.create(name='local_us')
|
||||
|
||||
ExternalNotificationEvent.create(name='repo_push')
|
||||
ExternalNotificationEvent.create(name='build_start')
|
||||
ExternalNotificationEvent.create(name='build_success')
|
||||
ExternalNotificationEvent.create(name='build_failure')
|
||||
|
||||
ExternalNotificationMethod.create(name='quay_notification')
|
||||
ExternalNotificationMethod.create(name='email')
|
||||
ExternalNotificationMethod.create(name='webhook')
|
||||
|
||||
|
||||
def wipe_database():
|
||||
logger.debug('Wiping all data from the DB.')
|
||||
|
|
Reference in a new issue