-
Notifications
You must be signed in to change notification settings - Fork 75
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bring R5 in line with analysis-backend v6.0.0
- Loading branch information
Showing
508 changed files
with
82,619 additions
and
31,334 deletions.
There are no files selected for viewing
This file contains 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,70 @@ | ||
name: Java CI | ||
# On [push, pull_request] causes double-builds when creating PRs. | ||
# But triggering on push only will miss pull requests from outside authors. | ||
on: | ||
# Should catch merged pull requests, pushes to Conveyal PR branches, and tags. | ||
# The push event's ref reveals the branch name for S3 upload, unlike pull_request which sees the merge target. | ||
push | ||
# Try to catch PRs from outside authors, which don't need to be uploaded to S3. | ||
# pull_request: | ||
# branches: | ||
# - dev | ||
# - master | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
# Start a separate docker container that we can contact over TCP (for tests) | ||
# Apparently there's something tricky going on with the port binding though | ||
# https://help.github.com/en/articles/workflow-syntax-for-github-actions#jobsjob_idservices | ||
services: | ||
mongodb: | ||
image: mongo:latest | ||
ports: | ||
- 27017:27017 | ||
# You can specify a docker container on which to run steps, rather than on the metal of runs-on above. | ||
# container: | ||
# image: mherwig/docker-alpine-java-mongo:latest | ||
# env: | ||
# BUILD_TARGET:staging | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
GPR_USERNAME: ${{ secrets.GPR_USERNAME }} | ||
GPR_TOKEN: ${{ secrets.GPR_TOKEN }} | ||
steps: | ||
# Starting in v2.2 checkout action fetches all tags when fetch-depth=0, for auto-versioning. | ||
- uses: actions/[email protected] | ||
with: | ||
fetch-depth: 0 | ||
# Java setup step completes very fast, no need to run in a preconfigured docker container | ||
- name: Set up JDK 11 | ||
uses: actions/setup-java@v1 | ||
with: | ||
java-version: 11 | ||
- uses: actions/cache@v1 | ||
id: cache | ||
with: | ||
path: ~/.gradle/caches | ||
key: gradle-caches | ||
- name: Build and Test | ||
run: gradle build | ||
- name: Ensure shadow JAR is runnable as backend | ||
run: | | ||
cp analysis.properties.template analysis.properties | ||
gradle testShadowJarRunnable | ||
- name: Publish to GH Packages | ||
run: gradle publish | ||
- name: Upload to S3 | ||
# Use git describe to get a similar string to the Gradle project version (possibly missing .dirty). | ||
run: | | ||
VERSION=$(gradle -q printVersion | head -n1) | ||
LOCAL_FILE=$(ls build/libs/*-all.jar | head -n1) | ||
aws s3 cp --no-progress --region eu-west-1 $LOCAL_FILE s3://r5-builds/${VERSION}.jar | ||
# If we are on the head of dev or master, also copy to branch-latest.jar. 'aws s3 cp' will overwrite by default. | ||
- name: Copy to branch-latest.jar on S3 | ||
if: github.ref == 'refs/heads/dev' || github.ref == 'refs/heads/master' | ||
run: | | ||
VERSION=$(gradle -q printVersion | head -n1) | ||
BRANCH=${GITHUB_REF#refs/heads/} | ||
echo VERSION is $VERSION, BRANCH is $BRANCH | ||
aws s3 cp --no-progress --region eu-west-1 s3://r5-builds/${VERSION}.jar s3://r5-builds/${BRANCH}-latest.jar |
This file was deleted.
Oops, something went wrong.
This file contains 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 |
---|---|---|
@@ -1,7 +1,50 @@ | ||
.idea | ||
.DS_Store | ||
.gradle/ | ||
/build/ | ||
/out/ | ||
|
||
# Ignore Gradle GUI config | ||
gradle-app.setting | ||
|
||
# Avoid ignoring Gradle wrapper jar file (.jar files are usually ignored) | ||
!gradle-wrapper.jar | ||
|
||
# Cache of project | ||
.gradletasknamecache | ||
|
||
# Other gradle build objects | ||
gradle | ||
gradlew.bat | ||
gradlew | ||
|
||
# IntelliJ IDEA | ||
.idea/ | ||
|
||
logs | ||
project/project | ||
project/target | ||
.target | ||
target | ||
hs_err_pid* | ||
cache | ||
*.iml | ||
.DS_Store | ||
tmp | ||
.history | ||
dist | ||
/.idea | ||
/*.iml | ||
/out | ||
/.idea_modules | ||
/.classpath | ||
/.project | ||
/RUNNING_PID | ||
/.settings | ||
/data | ||
s3credentials | ||
*.class | ||
/bin | ||
/cache/ | ||
*~ | ||
nbproject | ||
logentries.xml | ||
src/main/resources/git.properties | ||
pom.xml.versionsBackup | ||
analysis.properties | ||
/src/test/resources/snapshots/com/conveyal/analysis/controllers/ |
This file contains 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.
Oops, something went wrong.