-
Notifications
You must be signed in to change notification settings - Fork 23
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
Provides docker-compose alternative workflow for Valkyrie development #891
Open
dchandekstark
wants to merge
1
commit into
samvera:main
Choose a base branch
from
dchandekstark:890-docker-compose
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
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 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,7 @@ | ||
Dockerfile | ||
docker-compose.yml | ||
.bundle | ||
.circleci | ||
.ctags | ||
.dockerignore | ||
.lando.yml |
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,3 +1,4 @@ | ||
/.bash_history | ||
/.bundle/ | ||
/.yardoc | ||
/Gemfile.lock | ||
|
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,16 @@ | ||
ARG ruby_version=2.6 | ||
FROM ruby:${ruby_version} | ||
|
||
SHELL ["/bin/bash", "-c"] | ||
|
||
WORKDIR /opt/valkyrie | ||
|
||
COPY . . | ||
|
||
RUN chmod -R 0777 . | ||
|
||
USER 1001:0 | ||
|
||
ENV HOME=/opt/valkyrie | ||
|
||
RUN gem install bundler && bundle install |
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 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,7 @@ | ||
#!/bin/bash | ||
|
||
docker-compose up -d | ||
|
||
docker-compose exec valkyrie /bin/bash | ||
|
||
docker-compose down |
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,83 @@ | ||
version: '3.8' | ||
|
||
services: | ||
valkyrie: | ||
image: valkyrie | ||
build: | ||
context: . | ||
volumes: | ||
- .:/opt/valkyrie | ||
environment: | ||
- SOLR_URL=http://solr:8983/solr/valkyrie-core-test | ||
- DATABASE_URL=postgresql://postgres:valkyrie@db:5432/Valkyrie_gem_development | ||
- DATABASE_CLEANER_ALLOW_REMOTE_DATABASE_URL=true | ||
- RAILS_ENV=development | ||
- RACK_ENV=development | ||
- FEDORA_4_PORT=8080 | ||
- FEDORA_4_HOST=fcrepo4 | ||
- FEDORA_5_PORT=8080 | ||
- FEDORA_5_HOST=fcrepo5 | ||
- FEDORA_6_PORT=8080 | ||
- FEDORA_6_HOST=fcrepo6 | ||
command: | ||
- sleep | ||
- infinity | ||
|
||
solr: | ||
image: solr:7 | ||
ports: | ||
- "8994:8983" | ||
volumes: | ||
- ./solr/config:/solr_config | ||
- solr:/opt/solr/server/solr/mycores | ||
entrypoint: | ||
- docker-entrypoint.sh | ||
- solr-precreate | ||
- valkyrie-core-test | ||
- /solr_config | ||
|
||
db: | ||
image: postgres:10 | ||
volumes: | ||
- pgdata:/var/lib/postgresql/data | ||
environment: | ||
- POSTGRES_DB=Valkyrie_gem_development | ||
- POSTGRES_PASSWORD=valkyrie | ||
|
||
fcrepo4: | ||
image: samvera/fcrepo4:4.7.5 | ||
command: | ||
- /fedora-entrypoint.sh | ||
volumes: | ||
- fcrepo4:/data | ||
ports: | ||
- "8988:8080" | ||
|
||
fcrepo5: | ||
image: samvera/fcrepo4:5.1.0 | ||
command: | ||
- /fedora-entrypoint.sh | ||
volumes: | ||
- fcrepo5:/data | ||
ports: | ||
- "8998:8080" | ||
|
||
fcrepo6: | ||
image: fcrepo/fcrepo:6.0.0 | ||
command: | ||
- "catalina.sh" | ||
- "run" | ||
volumes: | ||
- fcrepo6:/data | ||
ports: | ||
- "8978:8080" | ||
environment: | ||
CATALINA_OPTS: "-Djava.awt.headless=true -Dfile.encoding=UTF-8 -server -Xms512m -Xmx1024m -XX:NewSize=256m -XX:MaxNewSize=256m -XX:PermSize=256m -XX:MaxPermSize=256m -XX:+DisableExplicitGC -Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true" | ||
JAVA_OPTS: "-Dfcrepo.dynamic.jms.port=61619 -Dfcrepo.dynamic.stomp.port=61615 -Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true" | ||
|
||
volumes: | ||
fcrepo4: | ||
fcrepo5: | ||
fcrepo6: | ||
solr: | ||
pgdata: |
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 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 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
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.
these lines cause me to get a permission error when i try to run
and since this isn't a production image i don't think we need to set a non-default user. this change got tests running for me (although i got a number of failures which i haven't looked into yet):