gitea/models/migrations
zeripath 886b1de949
Update the webauthn_credential_id_sequence in Postgres (#19048)
* Update the webauthn_credential_id_sequence in Postgres

There is (yet) another problem with v210 in that Postgres will silently allow preset
ID insertions ... but it will not update the sequence value.

This PR simply adds a little step to the end of the v210 migration to update the
sequence number.

Users who have already migrated who find that they cannot insert new
webauthn_credentials into the DB can either run:

```bash
gitea doctor recreate-table webauthn_credential
```

or

```bash
./gitea doctor --run=check-db-consistency --fix
```

which will fix the bad sequence.

Fix #19012

Signed-off-by: Andrew Thornton <art27@cantab.net>
2022-03-10 23:04:55 +01:00
..
fixtures Attempt to fix the webauthn migration again - part 3 (#18770) 2022-02-16 21:03:58 +00:00
migrations_test.go format with gofumpt (#18184) 2022-01-20 18:46:10 +01:00
migrations.go Fix page and missing return on unadopted repos API (#18848) 2022-02-27 20:17:42 +08:00
testlogger_test.go migrations: add test for importing pull requests in gitea uploader (#18752) 2022-02-25 17:20:50 +08:00
v70.go
v71.go Use base32 for 2FA scratch token (#18384) 2022-01-26 12:10:10 +08:00
v72.go
v73.go
v74.go
v75.go
v76.go
v77.go
v78.go
v79.go
v80.go
v81.go
v82.go Propagate context and ensure git commands run in request context (#17868) 2022-01-19 23:26:57 +00:00
v83.go
v84.go
v85.go Use base32 for 2FA scratch token (#18384) 2022-01-26 12:10:10 +08:00
v86.go
v87.go
v88.go
v89.go
v90.go
v91.go
v92.go
v93.go
v94.go
v95.go
v96.go
v97.go
v98.go
v99.go
v100.go
v101.go
v102.go
v103.go
v104.go
v105.go
v106.go
v107.go
v108.go
v109.go
v110.go
v111.go Move unit into models/unit/ (#17576) 2021-11-09 20:57:58 +01:00
v112.go
v113.go
v114.go
v115.go
v116.go
v117.go
v118.go
v119.go
v120.go
v121.go
v122.go
v123.go
v124.go
v125.go
v126.go
v127.go
v128.go Delete old git.NewCommand() and use it as git.NewCommandContext() (#18552) 2022-02-06 20:01:47 +01:00
v129.go
v130.go
v131.go
v132.go
v133.go
v134.go Delete old git.NewCommand() and use it as git.NewCommandContext() (#18552) 2022-02-06 20:01:47 +01:00
v135.go
v136.go Propagate context and ensure git commands run in request context (#17868) 2022-01-19 23:26:57 +00:00
v137.go
v138.go
v139.go
v140.go
v141.go
v142.go A better go code formatter, and now make fmt can run in Windows (#17684) 2021-11-17 20:34:35 +08:00
v143.go
v144.go A better go code formatter, and now make fmt can run in Windows (#17684) 2021-11-17 20:34:35 +08:00
v145.go
v146.go
v147.go
v148.go
v149.go
v150.go
v151.go
v152.go
v153.go
v154.go
v155.go
v156.go Propagate context and ensure git commands run in request context (#17868) 2022-01-19 23:26:57 +00:00
v157.go
v158.go
v159.go
v160.go
v161.go Fix database keyword quote problem on migration v161 (#17522) 2021-11-05 00:47:01 +02:00
v162.go
v163.go
v164.go
v165.go
v166.go
v167.go
v168.go
v169.go
v170.go
v171.go
v172.go
v173.go
v174.go
v175.go A better go code formatter, and now make fmt can run in Windows (#17684) 2021-11-17 20:34:35 +08:00
v176_test.go format with gofumpt (#18184) 2022-01-20 18:46:10 +01:00
v176.go
v177_test.go format with gofumpt (#18184) 2022-01-20 18:46:10 +01:00
v177.go
v178.go
v179.go
v180.go
v181_test.go format with gofumpt (#18184) 2022-01-20 18:46:10 +01:00
v181.go
v182_test.go format with gofumpt (#18184) 2022-01-20 18:46:10 +01:00
v182.go
v183.go
v184.go Check if column exist before rename if exist, just return with no error (#17870) 2021-12-02 21:17:24 +08:00
v185.go
v186.go
v187.go
v188.go
v189_test.go format with gofumpt (#18184) 2022-01-20 18:46:10 +01:00
v189.go
v190.go
v191.go format with gofumpt (#18184) 2022-01-20 18:46:10 +01:00
v192.go
v193_test.go
v193.go
v194.go
v195_test.go format with gofumpt (#18184) 2022-01-20 18:46:10 +01:00
v195.go
v196.go
v197.go
v198.go
v199.go Refactor update checker to use AppState (#17387) 2021-10-21 17:10:49 +01:00
v200.go
v201.go Refactor update checker to use AppState (#17387) 2021-10-21 17:10:49 +01:00
v202.go Add support for ssh commit signing (#17743) 2021-12-19 00:37:18 -05:00
v203.go Support sorting for project board issuses (#17152) 2021-12-08 14:57:18 +08:00
v204.go Migration 204 use Sync2 (#18044) 2021-12-20 18:58:38 +01:00
v205.go Increase Salt randomness (#18179) 2022-01-04 15:13:52 +00:00
v206.go Team permission allow different unit has different permission (#17811) 2022-01-05 11:37:00 +08:00
v207.go Attempt to fix the webauthn migration again - part 3 (#18770) 2022-02-16 21:03:58 +00:00
v208.go Attempt to fix the webauthn migration again - part 3 (#18770) 2022-02-16 21:03:58 +00:00
v209.go Attempt to fix the webauthn migration again - part 3 (#18770) 2022-02-16 21:03:58 +00:00
v210_test.go Lock gofumpt to v0.3.0 and run it (#18866) 2022-02-23 20:16:07 +00:00
v210.go Update the webauthn_credential_id_sequence in Postgres (#19048) 2022-03-10 23:04:55 +01:00