Skip to content

Commit

Permalink
Merge branch 'main' into develop
Browse files Browse the repository at this point in the history
# Conflicts:
#	migrations/20221121094350_drop-hashtag-uniqueness.js
#	pages/_app.js
#	src/pages/organizations/[id]/maintenance.js
  • Loading branch information
vgeorge committed Dec 15, 2022
2 parents 369338f + 2ee9c1c commit 9cc5fd1
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 51 deletions.
8 changes: 8 additions & 0 deletions app/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,14 @@ app.use(boom())
async function init() {
await nextApp.prepare()

// On maintenance mode, render maintenance page
if (process.env.MAINTENANCE_MODE === 'true') {
app.get('/*', (req, res) => {
return nextApp.render(req, res, '/maintenance')
})
return app
}

/**
* Sub apps init
*/
Expand Down
11 changes: 11 additions & 0 deletions migrations/20221121094350_drop-hashtag-uniqueness.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
exports.up = function (knex) {
return knex.schema.alterTable('team', function (table) {
table.dropUnique('hashtag')
})
}

exports.down = function (knex) {
return knex.schema.alterTable('team', function (table) {
table.unique('hashtag')
})
}
3 changes: 3 additions & 0 deletions src/pages/organizations/[id]/maintenance.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export default function MaintenancePage() {
return <div>OSM Teams is under maintenance, please come back soon.</div>
}
51 changes: 0 additions & 51 deletions tracing.yml

This file was deleted.

0 comments on commit 9cc5fd1

Please sign in to comment.