-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
GitHub actions #7035
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
GitHub actions #7035
Changes from all commits
Commits
Show all changes
48 commits
Select commit
Hold shift + click to select a range
88a2b0e
Trying to setup GitHub Actions
davimacedo dbca985
Try to fix the workflow steps
davimacedo b4d20ca
Fix NODE_VERSION
davimacedo 96c55d7
Fix services
davimacedo 84d9f9b
Fix services 2
davimacedo 09e13c3
Fix redis service, remove docker service
davimacedo 560e358
Missing npm install
davimacedo c6c48c4
Fix Use Node.js step name
davimacedo 84b8afa
Remove greenkeeper
davimacedo a4745c8
I believe we do not need this command
davimacedo 282443e
Try to include postgres
davimacedo 560fc8e
Fix postgres script
davimacedo 5b06bff
Remove before install script
davimacedo eb92553
Fix postgres before script
davimacedo e193496
Try to fix connection to postgres
davimacedo dafa558
Fix postgress port
davimacedo 65b3368
Postgres host
davimacedo 58c3a69
Still trying to connect on postgres
davimacedo 41be942
Still trying to connect on postgres - localhost
davimacedo 43331dc
Split postgres in a separate job
davimacedo c322d68
Add postgres healthcheck
davimacedo 4883548
Set postgres just like github example
davimacedo 82fdc69
Fix postgres scripts with new credentials
davimacedo 884fdfd
Still trying to fix postgres connection
davimacedo 13bc38b
Now it looks only the username is wrong
davimacedo 702a4e1
Passing postgres password in the right way
davimacedo 9311927
try to install postgis
davimacedo 8c283f0
New attempt to install postgis
davimacedo aed0ad0
Fix postgis image name
davimacedo 19d1cd0
Try to output tests
davimacedo b2f4714
We need to start mongo
davimacedo 7bf4bbd
Increase tests timeout
davimacedo 7679739
Fix flaky test
davimacedo 1e40452
Add GitHub Actions badge
davimacedo 5a57339
Badge as html
davimacedo 48fa133
Fix badge link
davimacedo 6b9d14e
Remove Travis
davimacedo 4966299
try to fix coverage
davimacedo 32654cf
Fix flaky test
davimacedo 7cc580a
Improve ci workflow
davimacedo eab6940
Change the mongo default test version
davimacedo 88b0c0b
Fix the job name in the if clause
davimacedo dd53117
Ubuntu18.0.4
davimacedo ac0d66c
Downgrade to 4.0.21
davimacedo 70c7cb4
Fix cache keys:
davimacedo f7a9e72
Trying with mongo 4.0.4
davimacedo 289cd44
Rever os and mongo versions
davimacedo b8dfcb9
remove latest node
davimacedo File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,110 @@ | ||
name: ci | ||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
branches: | ||
- '**' | ||
env: | ||
COVERAGE_OPTION: ./node_modules/.bin/nyc | ||
NODE_VERSION: 10 | ||
PARSE_SERVER_TEST_TIMEOUT: 20000 | ||
jobs: | ||
check-mongo: | ||
strategy: | ||
davimacedo marked this conversation as resolved.
Show resolved
Hide resolved
|
||
matrix: | ||
include: | ||
- name: Mongo 4.0.4, ReplicaSet, WiredTiger | ||
MONGODB_VERSION: 4.0.4 | ||
MONGODB_TOPOLOGY: replicaset | ||
davimacedo marked this conversation as resolved.
Show resolved
Hide resolved
|
||
MONGODB_STORAGE_ENGINE: wiredTiger | ||
NODE_VERSION: 10 | ||
- name: Mongo 3.6.21 | ||
MONGODB_VERSION: 3.6.21 | ||
NODE_VERSION: 10 | ||
- name: Redis Cache | ||
PARSE_SERVER_TEST_CACHE: redis | ||
NODE_VERSION: 10 | ||
- name: Node 12.12.0 | ||
NODE_VERSION: 12.12.0 | ||
davimacedo marked this conversation as resolved.
Show resolved
Hide resolved
|
||
name: ${{ matrix.name }} | ||
timeout-minutes: 30 | ||
runs-on: ubuntu-18.04 | ||
services: | ||
redis: | ||
image: redis | ||
ports: | ||
- 6379:6379 | ||
env: | ||
MONGODB_VERSION: ${{ matrix.MONGODB_VERSION }} | ||
MONGODB_TOPOLOGY: ${{ matrix.MONGODB_TOPOLOGY }} | ||
MONGODB_STORAGE_ENGINE: ${{ matrix.MONGODB_STORAGE_ENGINE }} | ||
PARSE_SERVER_TEST_CACHE: ${{ matrix.PARSE_SERVER_TEST_CACHE }} | ||
NODE_VERSION: ${{ matrix.NODE_VERSION }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Use Node.js ${{ matrix.NODE_VERSION }} | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: ${{ matrix.NODE_VERSION }} | ||
- name: Cache Node.js modules | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.npm | ||
key: ${{ runner.os }}-node-${{ matrix.NODE_VERSION }}-${{ hashFiles('**/package-lock.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-node-${{ matrix.NODE_VERSION }}- | ||
- name: Install dependencies | ||
run: npm ci | ||
- if: ${{ matrix.name == 'Mongo 3.6.21' }} | ||
run: npm run lint | ||
- run: npm run pretest | ||
- run: npm run coverage | ||
env: | ||
CI: true | ||
- run: bash <(curl -s https://codecov.io/bash) | ||
check-postgres: | ||
name: Postgresql | ||
timeout-minutes: 30 | ||
runs-on: ubuntu-18.04 | ||
services: | ||
redis: | ||
image: redis | ||
ports: | ||
- 6379:6379 | ||
postgres: | ||
image: postgis/postgis:11-3.0 | ||
env: | ||
POSTGRES_PASSWORD: postgres | ||
ports: | ||
- 5432:5432 | ||
options: >- | ||
--health-cmd pg_isready | ||
--health-interval 10s | ||
--health-timeout 5s | ||
--health-retries 5 | ||
env: | ||
PARSE_SERVER_TEST_DB: postgres | ||
POSTGRES_MAJOR_VERSION: 11 | ||
PARSE_SERVER_TEST_DATABASE_URI: postgres://postgres:postgres@localhost:5432/parse_server_postgres_adapter_test_database | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Use Node.js 10 | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: 10 | ||
- name: Cache Node.js modules | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.npm | ||
key: ${{ runner.os }}-node-${{ matrix.NODE_VERSION }}-${{ hashFiles('**/package-lock.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-node-${{ matrix.NODE_VERSION }}- | ||
- name: Install dependencies | ||
run: npm ci | ||
- run: bash scripts/before_script_postgres.sh | ||
- run: npm run coverage | ||
env: | ||
CI: true | ||
- run: bash <(curl -s https://codecov.io/bash) |
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@davimacedo just wondering, what is
COVERAGE_OPTION
used for? I haven't found any references.Edit: Found a ref, I think that can be removed, maybe from travis ci?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe it makes this to work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How so?
I believe it was part of a script in package.json, that has been removed:
cross-env NODE_ENV=test TESTING=1 ./node_modules/.bin/babel-node $COVERAGE_OPTION ./node_modules/jasmine/bin/jasmine.js
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You might be right. Let's try to remove it and see what happens.