-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #147 from hasadna/containerize-siri-collector
Containerize siri collector
- Loading branch information
Showing
27 changed files
with
796 additions
and
646 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 |
---|---|---|
@@ -1,12 +1,33 @@ | ||
language: python | ||
python: | ||
- "3.6" | ||
install: | ||
- pip install boto3 codecov coverage | ||
# commands to run tests | ||
script: | ||
- cd ./gtfs/gtfs_utils | ||
- python setup.py test | ||
- cd ../retriever/ | ||
- coverage run s3_wrapper_setup.py pytest | ||
- codecov | ||
matrix: | ||
include: | ||
- language: python | ||
python: | ||
- "3.6" | ||
install: | ||
- pip install boto3 codecov coverage | ||
# commands to run tests | ||
script: | ||
- cd ./gtfs/gtfs_utils | ||
- python setup.py test | ||
- cd ../retriever/ | ||
- coverage run s3_wrapper_setup.py pytest | ||
- codecov | ||
- language: java | ||
jdk: oraclejdk8 | ||
script: | ||
- cd ./siri/siri_retriever/siri-0.1 | ||
- ./mvnw install -DskipTests=true -Dmaven.javadoc.skip=true -B -V | ||
- docker login -u ${DOCKER_HUB_USERNAME} -p ${DOCKER_HUB_PASSWORD} | ||
- docker build -t siri-collector . | ||
- docker tag siri-collector openbus1/siri-collector:${TRAVIS_BRANCH} | ||
- docker push openbus1/siri-collector:${TRAVIS_BRANCH} | ||
- language: java | ||
jdk: oraclejdk8 | ||
script: | ||
- docker login -u ${DOCKER_HUB_USERNAME} -p ${DOCKER_HUB_PASSWORD} | ||
- cd ./siri/gtfs_reader | ||
- mvn install -DskipTests=true | ||
- docker build -t gtfs-collector . | ||
- docker tag gtfs-collector openbus1/gtfs-collector:${TRAVIS_BRANCH} | ||
- docker push openbus1/gtfs-collector:${TRAVIS_BRANCH} | ||
|
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,6 @@ | ||
version: "3" | ||
|
||
services: | ||
siri-collector: | ||
extra_hosts: | ||
- "siri.motrealtime.co.il:172.17.0.1" |
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,29 @@ | ||
version: "3" | ||
|
||
services: | ||
siri-collector: | ||
container_name: siri-collector | ||
image: openbus1/siri-collector:containerize-siri-collector | ||
environment: | ||
- spring.profiles.active=production | ||
- scheduler.data.file=/opt/hasadna/data/ | ||
- gtfs.schedules.location=/opt/hasadna/data/ | ||
- gtfs.dir.location=/opt/hasadna | ||
- SIRI_OUTPUT_PATH=/opt/hasadna/data/siri_output | ||
volumes: | ||
- ${SCHEDULE_DATA_HOST_PATH}:/opt/hasadna/data | ||
restart: always | ||
gtfs-collector: | ||
container_name: gtfs-collector | ||
image: openbus1/gtfs-collector:containerize-siri-collector | ||
environment: | ||
- gtfs.agencies=[3,4,5,7,8,14,15,16,18,19,25,30,31,32] | ||
- gtfs.dateOfLastDownload=2018-11-17 | ||
- gtfs.reschedule.url=http://siri-collector:8080/data/schedules/read/all | ||
- gtfs.dir.location=/opt/hasadna/data/ | ||
- gtfs.schedules.location=/opt/hasadna/data/ | ||
- gtfs.RawFilesBackupDirectory=/opt/hasadna/data/ | ||
volumes: | ||
- ${SCHEDULE_DATA_HOST_PATH}:/opt/hasadna/data | ||
restart: always | ||
|
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 +1,2 @@ | ||
/target/ | ||
.idea/ |
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 |
---|---|---|
@@ -0,0 +1,13 @@ | ||
FROM java:openjdk-8-jre-alpine | ||
|
||
LABEL vendor="hasadna" | ||
LABEL type="gtfs-collector" | ||
|
||
EXPOSE 8080 | ||
RUN mkdir -p /opt/hasadna/data/schedule_data | ||
RUN mkdir -p /opt/hasadna/data/gtfs_schedules | ||
RUN mkdir -p /opt/hasadna/data/siri_output | ||
|
||
ADD target/siri-client-0.0.1-SNAPSHOT.jar /opt/hasadna/siri-client.jar | ||
|
||
CMD ["java", "-Xmx2g", "-jar", "/opt/hasadna/siri-client.jar"] |
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
File renamed without changes.
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
Oops, something went wrong.