Skip to content

Commit

Permalink
Merge pull request #136 from EBISPOT/dev
Browse files Browse the repository at this point in the history
Survey banner and docker fix
  • Loading branch information
henrietteharmse authored May 20, 2024
2 parents 667e74f + 0c81b3a commit e9af33b
Show file tree
Hide file tree
Showing 6 changed files with 87 additions and 34 deletions.
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*.tar.gz filter=lfs diff=lfs merge=lfs -text
15 changes: 14 additions & 1 deletion .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ name: Build & publish zooma images
on:
push:
branches: [ "dev", "stable" ]
pull_request:
branches:
- dev

env:
REGISTRY: ghcr.io
Expand All @@ -17,6 +20,11 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v2
with:
lfs: true

- name: Pull Git LFS files
run: git lfs pull

- name: Log in to the Container registry
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
Expand All @@ -28,5 +36,10 @@ jobs:
- name: Build and push zooma Docker image
run: |
docker build -t ghcr.io/ebispot/zooma:${{ github.sha }} .
docker tag ghcr.io/ebispot/zooma:${{ github.sha }} ghcr.io/ebispot/zooma:${{ github.ref_name }}
if [[ "${{ github.event_name }}" == "pull_request" ]]; then
TAG="PR-${{ github.event.pull_request.number }}"
else
TAG="${{ github.ref_name }}"
fi
docker tag ghcr.io/ebispot/zooma:${{ github.sha }} ghcr.io/ebispot/zooma:${TAG}
docker push --all-tags ghcr.io/ebispot/zooma
6 changes: 6 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,22 @@ ENV ZOOMA_OPTS="-Xms1g -Xmx4g"
RUN mkdir /opt/zooma_github /opt/zooma
RUN apt-get update && apt-get install -y nano maven
COPY . /opt/zooma_github/

RUN rm -rf /root/.m2/
RUN tar -xvzf /opt/zooma_github/ols-client/lib/m2directory.tar.gz -C /root/

ENV OJDBC6="https://www.oracle.com/webapps/redirect/signon?nexturl=https://download.oracle.com/otn/utilities_drivers/jdbc/11204/ojdbc6.jar"
RUN wget $OJDBC6 -O /lib/ojdbc6.jar \
&& mvn install:install-file -DgroupId=com.oracle -DartifactId=ojdbc6 -Dpackaging=jar -Dversion=11.2.0.4 -Dfile=/lib/ojdbc6.jar \
&& test /root/.m2/repository/com/oracle/ojdbc6/11.2.0.4/ojdbc6-11.2.0.4.jar

RUN mvn install:install-file -DcreateChecksum=true -Dpackaging=jar -Dfile=/opt/zooma_github/zooma-lodestar/lib/jena-core-2.12.0.jar -DgroupId=org.apache.jena -DartifactId=jena-core -Dversion=2.12.0
RUN mvn install:install-file -DcreateChecksum=true -Dpackaging=jar -Dfile=/opt/zooma_github/zooma-lodestar/lib/jena-arq-2.12.0.jar -DgroupId=org.apache.jena -DartifactId=jena-arq -Dversion=2.12.0
RUN mvn install:install-file -DcreateChecksum=true -Dpackaging=jar -Dfile=/opt/zooma_github/zooma-lodestar/lib/lode-core-api-1.3.jar -DgroupId=ebi-lode -DartifactId=lode-core-api -Dversion=1.3
RUN mvn install:install-file -DcreateChecksum=true -Dpackaging=jar -Dfile=/opt/zooma_github/zooma-lodestar/lib/lode-virtuoso-impl-1.3.jar -DgroupId=ebi-lode -DartifactId=lode-virtuoso-impl -Dversion=1.3
RUN mvn install:install-file -DcreateChecksum=true -Dpackaging=jar -Dfile=/opt/zooma_github/zooma-ui/lib/jackson-mapper-asl-1.5.3.jar -DgroupId=org.codehaus.jackson -DartifactId=jackson-mapper-asl -Dversion=1.5.3
RUN mvn install:install-file -DcreateChecksum=true -Dpackaging=jar -Dfile=/opt/zooma_github/zooma-ui/lib/jackson-core-asl-1.5.3.jar -DgroupId=org.codehaus.jackson -DartifactId=jackson-core-asl -Dversion=1.5.3

RUN cd /opt/zooma_github && mvn clean package
RUN mkdir /opt/tmp && unzip /opt/zooma_github/zooma-builder-app/target/zooma-builder.zip -d /opt/tmp
RUN cp /opt/zooma_github/zooma-ui/target/zooma.war /usr/local/tomcat/webapps/
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ ZOOMA is an application for discovering optimal ontology mappings, developed by

## Deploying with Docker

The preferred method of deployment for ZOOMA is using Docker. If you would like to deploy **the entire OntoTools stack** (OLS, OxO, and ZOOMA), check out the [OntoTools Docker Config](https://github.com/EBISPOT/ontotools-docker-config) repository. If you would like to deploy **ZOOMA only**, read on.
The preferred method of deployment for ZOOMA is using Docker. If you would like to deploy **the entire OntoTools stack** (OLS, OxO, and ZOOMA), check out the [OntoTools Docker Config](https://github.com/EBISPOT/ontotools-docker-config) repository. If you would like to deploy **ZOOMA only**, read on

First, create the necessary volumes:

Expand Down
3 changes: 3 additions & 0 deletions ols-client/lib/m2directory.tar.gz
Git LFS file not shown
94 changes: 62 additions & 32 deletions zooma-ui/src/main/frontend/src/pages/Home.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -73,41 +73,71 @@ export default class Home extends Component<Props, State> {

return (
<main>
<Row>
<h3>Query</h3>
<Column small={12} medium={12}>
<p>Use the text box to find possible ontology mappings for free text terms in the ZOOMA repository of curated annotation knowledge. You can add one term (e.g. 'Homo sapiens') per line. If you also have a type for your term (e.g. 'organism'), put this after the term, separated by a tab.
If you are new to ZOOMA, take a look at our getting started guide.</p>
</Column>
<Column small={12} medium={12}>
<Row>
<Row>
<div className="mt-4">
<div style={{
backgroundColor: '#b2dce8',
padding: '12px 24px',
borderRadius: '8px',
marginBottom: '16px',
textAlign: 'justify',
overflowX: 'auto'
}}>
<p>
Do data resources managed by EMBL-EBI and our collaborators make a difference to your
work? <br/><br/>
Please take 10 minutes to fill in our annual user survey, and help us make the case for
why sustaining open data resources is critical for life sciences research.<br/><br/>
Survey link: <a href="https://www.surveymonkey.com/r/HJKYKTT?channel=[webpage]"
target="_blank">https://www.surveymonkey.com/r/HJKYKTT?channel=[webpage]</a>
</p>
</div>
</div>
</Row>
<Row>
<h3>Query</h3>
<Column small={12} medium={12}>
<Row className="align-right">
<a onClick={this.onClickShowExamples}>
Show me some examples...
</a>
<p>Use the text box to find possible ontology mappings for free text terms in the ZOOMA
repository of curated annotation knowledge. You can add one term (e.g. 'Homo sapiens') per
line. If you also have a type for your term (e.g. 'organism'), put this after the term,
separated by a tab.
If you are new to ZOOMA, take a look at our getting started guide.</p>
</Column>
<Column small={12} medium={12}>
<Row>
<Column small={12} medium={12}>
<Row className="align-right">
<a onClick={this.onClickShowExamples}>
Show me some examples...
</a>
</Row>
</Column>
</Row>
<Row>
<textarea style={{minHeight: '300px'}} value={this.state.query}
onChange={this.onEditQuery}></textarea>
</Row>
</Column>
</Row>
<Row>
<textarea style={{minHeight: '300px'}} value={this.state.query} onChange={this.onEditQuery}></textarea>
</Row>
</Column>
</Row>
<Row>
<h3>Datasources</h3>
<Column small={12} medium={12}>
<p>ZOOMA maps text to ontology terms based on curated mappings from selected datasources (more preferred), and by searching ontologies directly (less preferred). Here, you can select which curated datasources to use, optionally ranked in order of preference. You can also select which ontologies to search directly.</p>
</Column>
<Column small={12} medium={12}>
{
this.state.datasources &&
this.state.datasourceConfig &&
<Datasources datasources={this.state.datasources} datasourceConfig={this.state.datasourceConfig} onConfigChanged={this.onDatasourceConfigChanged} />
}
</Column>
</Row>
<br/>
</Row>
<Row>
<h3>Datasources</h3>
<Column small={12} medium={12}>
<p>ZOOMA maps text to ontology terms based on curated mappings from selected datasources (more
preferred), and by searching ontologies directly (less preferred). Here, you can select
which curated datasources to use, optionally ranked in order of preference. You can also
select which ontologies to search directly.</p>
</Column>
<Column small={12} medium={12}>
{
this.state.datasources &&
this.state.datasourceConfig &&
<Datasources datasources={this.state.datasources}
datasourceConfig={this.state.datasourceConfig}
onConfigChanged={this.onDatasourceConfigChanged}/>
}
</Column>
</Row>
<br/>
<Row className="align-center">
<button className="button large"
disabled={this.state.searching}
Expand Down

0 comments on commit e9af33b

Please sign in to comment.