-
Notifications
You must be signed in to change notification settings - Fork 16
Add dev environment and update docs #79
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
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
92eb572
Add hot reloading dev environment.
guzman-raphael c45a2ec
Update version.
guzman-raphael 6544ff1
Add as draft verison.
guzman-raphael 3b32250
Add diff summary at the end of CHANGELOG.md.
guzman-raphael 06d688e
Bump change log reader action.
guzman-raphael 499506e
Bump change log reader action2.
guzman-raphael 3be0cf4
Simply compose dependencies and update docs.
guzman-raphael 1d1ccc7
Fix typos.
guzman-raphael d1cddc3
Update changelog.
guzman-raphael 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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,14 +1,36 @@ | ||
| # PHARUS_VERSION=$(cat pharus/version.py | tail -1 | awk -F\' '{print $2}') docker-compose -f docker-compose-deploy.yaml pull | ||
| # PHARUS_VERSION=$(cat pharus/version.py | tail -1 | awk -F\' '{print $2}') docker-compose -f docker-compose-deploy.yaml up -d | ||
| # Note: You must run both commands above | ||
| # PHARUS_VERSION=0.1.0a5 docker-compose -f docker-compose-deploy.yaml pull | ||
| # PHARUS_VERSION=0.1.0a5 docker-compose -f docker-compose-deploy.yaml up -d | ||
| # | ||
| # Intended for production deployment. | ||
| # Note: You must run both commands above for minimal outage | ||
| # Make sure to add an entry into your /etc/hosts file as `127.0.0.1 fakeservices.datajoint.io` | ||
| # This serves as an alias for the domain to resolve locally. | ||
| # With this config and the configuration below in NGINX, you should be able to verify it is | ||
| # running properly with a `curl https://fakeservices.datajoint.io/api/version`. | ||
| version: "2.4" | ||
| x-net: &net | ||
| networks: | ||
| - main | ||
| services: | ||
| pharus: | ||
| extends: | ||
| file: ./docker-compose-base.yaml | ||
| service: pharus | ||
| <<: *net | ||
| image: datajoint/pharus:${PHARUS_VERSION} | ||
| # environment: # configurable values with defaults | ||
| # - PHARUS_PORT=5000 | ||
| # - PHARUS_PREFIX=/ | ||
| fakeservices.datajoint.io: | ||
| <<: *net | ||
| image: raphaelguzman/nginx:v0.0.15 | ||
| environment: | ||
| - PHARUS_PORT=5000 | ||
| - PHARUS_PREFIX=/now | ||
| - ADD_pharus_TYPE=REST | ||
| - ADD_pharus_ENDPOINT=pharus:5000 | ||
| - ADD_pharus_PREFIX=/api | ||
| - HTTPS_PASSTHRU=TRUE | ||
| ports: | ||
| - "5000:5000" | ||
| - "443:443" | ||
| - "80:80" | ||
| depends_on: | ||
| pharus: | ||
| condition: service_healthy | ||
| networks: | ||
| main: |
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,39 @@ | ||
| # PY_VER=3.8 IMAGE=djbase DISTRO=alpine PHARUS_VERSION=$(cat pharus/version.py | tail -1 | awk -F\' '{print $2}') HOST_UID=$(id -u) docker-compose -f docker-compose-dev.yaml up | ||
| # | ||
| # Intended for normal development. Supports hot/live reloading. | ||
| # Note: If requirements or Dockerfile change, will need to add --build flag to docker-compose. | ||
| # Make sure to add an entry into your /etc/hosts file as `127.0.0.1 fakeservices.datajoint.io` | ||
| # This serves as an alias for the domain to resolve locally. | ||
| # With this config and the configuration below in NGINX, you should be able to verify it is | ||
| # running properly with a `curl https://fakeservices.datajoint.io/api/version`. | ||
| version: "2.4" | ||
| x-net: &net | ||
| networks: | ||
| - main | ||
| services: | ||
| pharus: | ||
| <<: *net | ||
| extends: | ||
| file: ./docker-compose-build.yaml | ||
| service: pharus | ||
| environment: | ||
| - FLASK_ENV=development # enables logging to console from Flask | ||
| volumes: | ||
| - ./pharus:/opt/conda/lib/python3.8/site-packages/pharus | ||
| command: pharus | ||
| fakeservices.datajoint.io: | ||
| <<: *net | ||
| image: raphaelguzman/nginx:v0.0.15 | ||
| environment: | ||
| - ADD_pharus_TYPE=REST | ||
| - ADD_pharus_ENDPOINT=pharus:5000 | ||
| - ADD_pharus_PREFIX=/api | ||
| - HTTPS_PASSTHRU=TRUE | ||
| ports: | ||
| - "443:443" | ||
| - "80:80" | ||
| depends_on: | ||
| pharus: | ||
| condition: service_healthy | ||
| networks: | ||
| main: | ||
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.
Should this be hosted on a datajoint dockerhub verse our own dev username?
Uh oh!
There was an error while loading. Please reload this page.
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.
@Synicix Good catch. Unfortunately, this one is tricky to solve properly... It is a repo I created a long while back that I wasn't sure if we would need it but now it has grown to be dependent on various projects. I'd like to move it now but it would have breaking changes for other projects. Let's use it for now and I can mirror it to a
datajointorvathespublic repo soon to give some time for us to migrate things over.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 will file an issue for it then. Just as a concern