Add migrations needed to encrypt feature flags client tokens

Make plaintext token column not null, add new token_encrypted column and
index on project_id & token_encrypted.

Post deployment migration to encrypt existing tokens.
101 jobs for 57918-encrypt-feature-flags-tokens in 69 minutes and 15 seconds (queued for 5 seconds)
Status Job ID Name Coverage
  Build
manual #233055601
gitlab-org allowed to fail manual
review-docs-deploy-manual
 
  Prepare
passed #233055603
gitlab-org
compile-assets

00:10:44

passed #233055605
gitlab-org
retrieve-tests-metadata

00:02:06

passed #233055604
gitlab-org
setup-test-env

00:06:13

 
  Test
passed #233055688
docker gitlab-org
build-qa-image

00:05:07

passed #233055616
allowed to fail
code_quality

00:08:06

passed #233055690
gitlab-org
danger-review

00:01:52

passed #233055681
gitlab-org
db:check-schema-pg

00:03:03

passed #233055680
gitlab-org
db:migrate:reset-mysql

00:04:39

passed #233055679
gitlab-org
db:migrate:reset-pg

00:02:23

passed #233055685
gitlab-org
db:rollback-mysql

00:04:05

passed #233055684
gitlab-org
db:rollback-pg

00:02:51

passed #233055618
allowed to fail
dependency_scanning

00:17:59

passed #233055606
gitlab-org
docs lint

00:02:55

passed #233055674
gitlab-org
downtime_check

00:02:39

passed #233055678
gitlab-org
ee_compat_check

00:03:18

passed #233055607
gitlab-org docker
gitlab:assets:compile

00:19:06

passed #233055687
gitlab-org
gitlab:setup-mysql

00:06:16

passed #233055686
gitlab-org
gitlab:setup-pg

00:04:18

failed #233055608
gitlab-org allowed to fail
gitlab:ui:visual

00:01:36

passed #233055691
gitlab-org
gitlab_git_test

00:01:06

passed #233055610
gitlab-org
jest

00:13:00

passed #233055609
gitlab-org
karma

00:11:24

54.56%
passed #233055693
gitlab-org
lint-ci-gitlab

00:00:41

passed #233055683
gitlab-org
migration:path-mysql

00:04:45

passed #233055682
gitlab-org
migration:path-pg

00:05:20

passed #233055692
gitlab-org
no_ee_check

00:00:24

passed #233055614
gitlab-org
qa-frontend-node:10

00:14:03

passed #233055613
gitlab-org
qa-frontend-node:8

00:14:59

passed #233055615
gitlab-org allowed to fail
qa-frontend-node:latest

00:12:19

passed #233055611
gitlab-org
qa:internal

00:02:55

passed #233055612
gitlab-org
qa:selectors

00:02:47

failed #233055689
allowed to fail manual
review-build-cng

00:22:42

passed #233055639
gitlab-org
rspec integration pg 1/6

00:16:30

passed #233055640
gitlab-org
rspec integration pg 2/6

00:15:33

passed #233055641
gitlab-org
rspec integration pg 3/6

00:16:58

passed #233055642
gitlab-org
rspec integration pg 4/6

00:14:55

passed #233055643
gitlab-org
rspec integration pg 5/6

00:13:58

passed #233055644
gitlab-org
rspec integration pg 6/6

00:15:09

passed #233055645
gitlab-org
rspec system pg 1/24

00:17:54

passed #233055654
gitlab-org
rspec system pg 10/24

00:13:36

passed #233055655
gitlab-org
rspec system pg 11/24

00:13:58

passed #233055656
gitlab-org
rspec system pg 12/24

00:14:21

passed #233055659
gitlab-org
rspec system pg 13/24

00:11:19

passed #233055661
gitlab-org
rspec system pg 14/24

00:12:58

passed #233055662
gitlab-org
rspec system pg 15/24

00:12:32

passed #233055663
gitlab-org
rspec system pg 16/24

00:11:13

passed #233055664
gitlab-org
rspec system pg 17/24

00:12:48

passed #233055665
gitlab-org
rspec system pg 18/24

00:14:36

passed #233055666
gitlab-org
rspec system pg 19/24

00:15:53

passed #233055646
gitlab-org
rspec system pg 2/24

00:15:34

passed #233055667
gitlab-org
rspec system pg 20/24

00:11:44

passed #233055668
gitlab-org
rspec system pg 21/24

00:13:31

passed #233055669
gitlab-org
rspec system pg 22/24

00:10:31

passed #233055670
gitlab-org
rspec system pg 23/24

00:11:12

passed #233055671
gitlab-org
rspec system pg 24/24

00:10:03

passed #233055647
gitlab-org
rspec system pg 3/24

00:13:35

passed #233055648
gitlab-org
rspec system pg 4/24

00:13:16

passed #233055649
gitlab-org
rspec system pg 5/24

00:12:03

passed #233055650
gitlab-org
rspec system pg 6/24

00:11:38

passed #233055651
gitlab-org
rspec system pg 7/24

00:14:38

passed #233055652
gitlab-org
rspec system pg 8/24

00:12:42

passed #233055653
gitlab-org
rspec system pg 9/24

00:13:20

passed #233055619
gitlab-org
rspec unit pg 1/20

00:12:36

passed #233055628
gitlab-org
rspec unit pg 10/20

00:15:43

passed #233055629
gitlab-org
rspec unit pg 11/20

00:17:29

passed #233055630
gitlab-org
rspec unit pg 12/20

00:19:49

passed #233055631
gitlab-org
rspec unit pg 13/20

00:16:26

passed #233055632
gitlab-org
rspec unit pg 14/20

00:13:39

passed #233055633
gitlab-org
rspec unit pg 15/20

00:16:58

passed #233055634
gitlab-org
rspec unit pg 16/20

00:16:22

passed #233055635
gitlab-org
rspec unit pg 17/20

00:16:32

passed #233055636
gitlab-org
rspec unit pg 18/20

00:17:06

passed #233055637
gitlab-org
rspec unit pg 19/20

00:13:54

passed #233055620
gitlab-org
rspec unit pg 2/20

00:15:22

passed #233055638
gitlab-org
rspec unit pg 20/20

00:15:57

passed #233055621
gitlab-org
rspec unit pg 3/20

00:12:18

passed #233055622
gitlab-org
rspec unit pg 4/20

00:11:41

passed #233055623
gitlab-org
rspec unit pg 5/20

00:11:21

passed #233055624
gitlab-org
rspec unit pg 6/20

00:13:52

passed #233055625
gitlab-org
rspec unit pg 7/20

00:12:27

passed #233055626
gitlab-org
rspec unit pg 8/20

00:15:37

passed #233055627
gitlab-org
rspec unit pg 9/20

00:18:20

passed #233055672
gitlab-org
rspec-fast-spec-helper

00:03:50

failed #233055617
allowed to fail
sast

00:33:58

passed #233055673
gitlab-org
static-analysis

00:13:23

 
  Review
manual #233055694
allowed to fail manual
package-and-qa
passed #233055695
gitlab-org allowed to fail
review-deploy

00:11:56

failed #233055698
gitlab-org allowed to fail manual
review-stop

00:00:22

 
  Qa
passed #233055706
docker gitlab-org allowed to fail
review-performance

00:02:59

manual #233055701
docker gitlab-org allowed to fail manual
review-qa-all 1/5
manual #233055702
docker gitlab-org allowed to fail manual
review-qa-all 2/5
manual #233055703
docker gitlab-org allowed to fail manual
review-qa-all 3/5
manual #233055704
docker gitlab-org allowed to fail manual
review-qa-all 4/5
manual #233055705
docker gitlab-org allowed to fail manual
review-qa-all 5/5
passed #233055700
docker gitlab-org allowed to fail
review-qa-smoke

00:03:31

 
  Post Test
passed #233055710
gitlab-org
coverage

00:03:14

95.73%
passed #233055712
gitlab-org allowed to fail
flaky-examples-check

00:02:00

passed #233055709
gitlab-org
jsdoc

00:01:30

passed #233055707
gitlab-org
lint:javascript:report

00:01:09

 
  Post Cleanup
manual #233055714
gitlab-org allowed to fail manual
review-docs-cleanup
 
Name Stage Failure
failed
review-stop Review
Created fresh repository.
fatal: Couldn't find remote ref refs/heads/57918-encrypt-feature-flags-tokens
Fetching changes with git depth set to 1...
Reinitialized existing Git repository in /builds/gitlab-org/gitlab-ce/.git/
fatal: Couldn't find remote ref refs/heads/57918-encrypt-feature-flags-tokens
Fetching changes with git depth set to 1...
Reinitialized existing Git repository in /builds/gitlab-org/gitlab-ce/.git/
fatal: Couldn't find remote ref refs/heads/57918-encrypt-feature-flags-tokens
ERROR: Job failed: exit code 1
failed
review-build-cng Test
Waiting for downstream pipeline status
......................./scripts/trigger-build:204:in `block in wait!': Pipeline did not succeed! (RuntimeError)
from ./scripts/trigger-build:193:in `loop'
from ./scripts/trigger-build:193:in `wait!'
from ./scripts/trigger-build:234:in `<main>'
Running after script...
$ date
Tue Jun 18 00:02:38 UTC 2019
ERROR: Job failed: exit code 1
failed
sast Test
2019/06/17 23:57:06 Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
2019/06/17 23:57:06 Timeout when running the analyzer
Running after script...
$ date
Mon Jun 17 23:57:14 UTC 2019
Uploading artifacts...
WARNING: gl-sast-report.json: no matching files
ERROR: No files to upload
ERROR: Job failed: exit code 1
failed
gitlab:ui:visual Test
$ cp public/assets/application-*.css gitlab-ui/styles/application.css
cp: cannot create regular file 'gitlab-ui/styles/application.css': No such file or directory
Running after script...
$ date
Mon Jun 17 23:24:46 UTC 2019
Uploading artifacts...
gitlab-ui/tests/__image_snapshots__/: found 112 matching files
Uploading artifacts to coordinator... ok
id=233055608 responseStatus=201 Created token=W7yEWxH6
ERROR: Job failed: exit code 1