mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
Merge pull request #62 from overleaf/csh-acceptance-test-creds2
Move acceptance test cred to docker-compose-config.yml
This commit is contained in:
commit
a11ea11e31
9 changed files with 29 additions and 17 deletions
|
@ -8,7 +8,7 @@
|
||||||
"prettier/standard"
|
"prettier/standard"
|
||||||
],
|
],
|
||||||
"parserOptions": {
|
"parserOptions": {
|
||||||
"ecmaVersion": 2017
|
"ecmaVersion": 2018
|
||||||
},
|
},
|
||||||
"plugins": [
|
"plugins": [
|
||||||
"mocha",
|
"mocha",
|
||||||
|
|
4
services/docstore/Jenkinsfile
vendored
4
services/docstore/Jenkinsfile
vendored
|
@ -52,9 +52,7 @@ pipeline {
|
||||||
|
|
||||||
stage('Acceptance Tests') {
|
stage('Acceptance Tests') {
|
||||||
steps {
|
steps {
|
||||||
withCredentials([usernamePassword(credentialsId: 'S3_DOCSTORE_TEST_AWS_KEYS', passwordVariable: 'AWS_SECRET_ACCESS_KEY', usernameVariable: 'AWS_ACCESS_KEY_ID')]) {
|
sh 'DOCKER_COMPOSE_FLAGS="-f docker-compose.ci.yml" make test_acceptance'
|
||||||
sh 'AWS_BUCKET="sl-acceptance-tests" AWS_ACCESS_KEY_ID=$AWS_ACCESS_KEY_ID AWS_SECRET_ACCESS_KEY=$AWS_SECRET_ACCESS_KEY DOCKER_COMPOSE_FLAGS="-f docker-compose.ci.yml" make test_acceptance'
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -12,9 +12,6 @@ DOCKER_COMPOSE := BUILD_NUMBER=$(BUILD_NUMBER) \
|
||||||
BRANCH_NAME=$(BRANCH_NAME) \
|
BRANCH_NAME=$(BRANCH_NAME) \
|
||||||
PROJECT_NAME=$(PROJECT_NAME) \
|
PROJECT_NAME=$(PROJECT_NAME) \
|
||||||
MOCHA_GREP=${MOCHA_GREP} \
|
MOCHA_GREP=${MOCHA_GREP} \
|
||||||
AWS_BUCKET=${AWS_BUCKET} \
|
|
||||||
AWS_ACCESS_KEY_ID=${AWS_ACCESS_KEY_ID} \
|
|
||||||
AWS_SECRET_ACCESS_KEY=${AWS_SECRET_ACCESS_KEY} \
|
|
||||||
docker-compose ${DOCKER_COMPOSE_FLAGS}
|
docker-compose ${DOCKER_COMPOSE_FLAGS}
|
||||||
|
|
||||||
DOCKER_COMPOSE_TEST_ACCEPTANCE = \
|
DOCKER_COMPOSE_TEST_ACCEPTANCE = \
|
||||||
|
|
|
@ -3,7 +3,10 @@ overleaf/docstore
|
||||||
|
|
||||||
A CRUD API for storing and updating text documents in projects
|
A CRUD API for storing and updating text documents in projects
|
||||||
|
|
||||||
|
## Tests
|
||||||
|
```
|
||||||
|
AWS_BUCKET=**** AWS_ACCESS_KEY_ID=**** AWS_SECRET_ACCESS_KEY=**** make test
|
||||||
|
```
|
||||||
License
|
License
|
||||||
-------
|
-------
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
docstore
|
docstore
|
||||||
--acceptance-creds=aws
|
--acceptance-creds=None
|
||||||
--dependencies=mongo
|
--dependencies=mongo
|
||||||
--docker-repos=gcr.io/overleaf-ops
|
--docker-repos=gcr.io/overleaf-ops
|
||||||
--env-add=
|
--env-add=
|
||||||
|
@ -7,4 +7,4 @@ docstore
|
||||||
--language=es
|
--language=es
|
||||||
--node-version=10.21.0
|
--node-version=10.21.0
|
||||||
--public-repo=True
|
--public-repo=True
|
||||||
--script-version=2.2.0
|
--script-version=2.3.0
|
||||||
|
|
14
services/docstore/docker-compose-config.yml
Normal file
14
services/docstore/docker-compose-config.yml
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
version: "2.3"
|
||||||
|
|
||||||
|
services:
|
||||||
|
dev:
|
||||||
|
environment:
|
||||||
|
- AWS_BUCKET
|
||||||
|
- AWS_ACCESS_KEY_ID
|
||||||
|
- AWS_SECRET_ACCESS_KEY
|
||||||
|
|
||||||
|
ci:
|
||||||
|
environment:
|
||||||
|
- AWS_BUCKET
|
||||||
|
- AWS_ACCESS_KEY_ID
|
||||||
|
- AWS_SECRET_ACCESS_KEY
|
|
@ -16,14 +16,14 @@ services:
|
||||||
test_acceptance:
|
test_acceptance:
|
||||||
build: .
|
build: .
|
||||||
image: ci/$PROJECT_NAME:$BRANCH_NAME-$BUILD_NUMBER
|
image: ci/$PROJECT_NAME:$BRANCH_NAME-$BUILD_NUMBER
|
||||||
|
extends:
|
||||||
|
file: docker-compose-config.yml
|
||||||
|
service: ci
|
||||||
environment:
|
environment:
|
||||||
ELASTIC_SEARCH_DSN: es:9200
|
ELASTIC_SEARCH_DSN: es:9200
|
||||||
REDIS_HOST: redis
|
REDIS_HOST: redis
|
||||||
MONGO_HOST: mongo
|
MONGO_HOST: mongo
|
||||||
POSTGRES_HOST: postgres
|
POSTGRES_HOST: postgres
|
||||||
AWS_ACCESS_KEY_ID: ${AWS_ACCESS_KEY_ID}
|
|
||||||
AWS_SECRET_ACCESS_KEY: ${AWS_SECRET_ACCESS_KEY}
|
|
||||||
AWS_BUCKET: ${AWS_BUCKET}
|
|
||||||
MOCHA_GREP: ${MOCHA_GREP}
|
MOCHA_GREP: ${MOCHA_GREP}
|
||||||
NODE_ENV: test
|
NODE_ENV: test
|
||||||
depends_on:
|
depends_on:
|
||||||
|
|
|
@ -21,14 +21,14 @@ services:
|
||||||
volumes:
|
volumes:
|
||||||
- .:/app
|
- .:/app
|
||||||
working_dir: /app
|
working_dir: /app
|
||||||
|
extends:
|
||||||
|
file: docker-compose-config.yml
|
||||||
|
service: dev
|
||||||
environment:
|
environment:
|
||||||
ELASTIC_SEARCH_DSN: es:9200
|
ELASTIC_SEARCH_DSN: es:9200
|
||||||
REDIS_HOST: redis
|
REDIS_HOST: redis
|
||||||
MONGO_HOST: mongo
|
MONGO_HOST: mongo
|
||||||
POSTGRES_HOST: postgres
|
POSTGRES_HOST: postgres
|
||||||
AWS_ACCESS_KEY_ID: ${AWS_ACCESS_KEY_ID}
|
|
||||||
AWS_SECRET_ACCESS_KEY: ${AWS_SECRET_ACCESS_KEY}
|
|
||||||
AWS_BUCKET: ${AWS_BUCKET}
|
|
||||||
MOCHA_GREP: ${MOCHA_GREP}
|
MOCHA_GREP: ${MOCHA_GREP}
|
||||||
LOG_LEVEL: ERROR
|
LOG_LEVEL: ERROR
|
||||||
NODE_ENV: test
|
NODE_ENV: test
|
||||||
|
|
|
@ -48,7 +48,7 @@
|
||||||
"eslint-plugin-react": "^7.19.0",
|
"eslint-plugin-react": "^7.19.0",
|
||||||
"eslint-plugin-standard": "^4.0.1",
|
"eslint-plugin-standard": "^4.0.1",
|
||||||
"mocha": "^7.1.1",
|
"mocha": "^7.1.1",
|
||||||
"prettier": "^2.0.1",
|
"prettier": "^2.0.0",
|
||||||
"prettier-eslint-cli": "^5.0.0",
|
"prettier-eslint-cli": "^5.0.0",
|
||||||
"request": "~2.88.2",
|
"request": "~2.88.2",
|
||||||
"sandboxed-module": "~2.0.3",
|
"sandboxed-module": "~2.0.3",
|
||||||
|
|
Loading…
Reference in a new issue