-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit c2d8c33
Showing
118 changed files
with
10,911 additions
and
0 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,30 @@ | ||
# FROM web_base | ||
FROM python:3.9 | ||
|
||
WORKDIR /app | ||
|
||
COPY requirements.txt requirements.txt | ||
# COPY ./docker_base/wait-for-it.sh wait-for-it.sh | ||
|
||
RUN pip install -r requirements.txt | ||
|
||
COPY ./wait-for-it.sh /wait-for-it.sh | ||
|
||
# create the app user | ||
RUN addgroup --system app && adduser --system --group app | ||
|
||
ENV APP_HOME /app | ||
RUN chown -R app:app $APP_HOME | ||
RUN ["chmod", "+x", "/wait-for-it.sh"] | ||
|
||
RUN rm /etc/nginx/conf.d/default.conf | ||
COPY ./services/nginx/nginx.conf /etc/nginx/conf.d | ||
|
||
# change to the app user | ||
USER app | ||
|
||
|
||
# CMD ["/bin/bash"] | ||
# if you want to debug something | ||
|
||
# CMD ["/wait-for-it.sh", "db:8080", "--", "python", "app.py","80"] |
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 @@ | ||
ISC License (ISC) | ||
================================== | ||
_Copyright 2021 marilenadaquino_ | ||
|
||
Permission to use, copy, modify, and/or distribute this software for any purpose with or | ||
without fee is hereby granted, provided that the above copyright notice and this permission | ||
notice appear in all copies. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS | ||
SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL | ||
THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE | ||
OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. |
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,23 @@ | ||
--- | ||
id: clef | ||
name: CLEF, Crowdsourcing Linked Entities via web Form | ||
brief-description: CLEF is a lightweight Linked Open Data native cataloguing system tailored to small-medium crowdsourcing projects. | ||
type: Application | ||
release-date: 2021-10-27 | ||
release-number: latest | ||
work-package: WP1 | ||
keywords: | ||
- crowdsourcing | ||
- linked open data | ||
- registry | ||
licence: ISC | ||
release link: https://github.com/polifonia-project/clef/releases/latest | ||
demo: https://projects.dharc.unibo.it/musow/ | ||
running-instance: https://projects.dharc.unibo.it/musow/ | ||
credits: Marilena Daquino (UNIBO), Martin Hlosta (FFHS, external collaborator), Mari Wigham (NISV), Enrico Daga (OU) | ||
|
||
--- | ||
|
||
Working demo: https://projects.dharc.unibo.it/musow/. | ||
|
||
Documentation. |
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 @@ | ||
VAGRANTFILE_API_VERSION = "2" | ||
|
||
$bootstrap = <<SCRIPT | ||
apt-get update | ||
apt-get install -y bzip2 | ||
apt-get install -y python-pip python-dev python3-pip | ||
apt-get install -y curl | ||
apt-get install -y xvfb | ||
apt-get -y install openjdk-8-jdk | ||
apt install -y python3.7 | ||
update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.6 1 | ||
update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.7 2 | ||
python3.7 -m pip install pip | ||
SCRIPT | ||
|
||
$install = <<SCRIPT | ||
BLAZEGRAPH_PATH="/var/lib/blazegraph.jar" | ||
if [ ! -f "$BLAZEGRAPH_PATH" ]; then | ||
curl -L "https://github.com/blazegraph/database/releases/download/BLAZEGRAPH_2_1_6_RC/blazegraph.jar" --output $BLAZEGRAPH_PATH | ||
fi | ||
SCRIPT | ||
|
||
$web_install = <<SCRIPT | ||
APP_DIR="/app" | ||
echo -n "Installing webapp..." | ||
python3.7 -m pip install --upgrade pip | ||
python3.7 -m pip install -r $APP_DIR/requirements.txt | ||
SCRIPT | ||
|
||
$web_run = <<SCRIPT | ||
BLAZEGRAPH_PATH="/var/lib/blazegraph.jar" | ||
BLAZEGRAPH_PORT=3000 | ||
BLAZEGRAPH_PROPERTY_FILE="/app/blaze_vm.properties" | ||
APP_DIR="/app" | ||
WEBAPP_PORT=8080 | ||
echo -n "Running Blazegraph..." | ||
lsof -ti tcp:${BLAZEGRAPH_PORT} | xargs kill | ||
java -Dfile.encoding=UTF-8 -Dsun.jnu.encoding=UTF-8 -server -Xmx2g -Djetty.port=${BLAZEGRAPH_PORT} -Dbigdata.propertyFile=$BLAZEGRAPH_PROPERTY_FILE -jar $BLAZEGRAPH_PATH & | ||
sleep 3 | ||
echo -n "Running webapp..." | ||
cd $APP_DIR | ||
python3 app.py $WEBAPP_PORT & | ||
SCRIPT | ||
|
||
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| | ||
# Every Vagrant virtual environment requires a box to build off of. | ||
config.vm.box = "hashicorp/bionic64" | ||
config.vm.synced_folder "./", "/app", create: true | ||
config.vm.synced_folder "./data/", "/data", create: true | ||
|
||
config.vm.network "forwarded_port", guest: 8080, host: 8080 | ||
config.vm.network "forwarded_port", guest: 3000, host: 3000 | ||
|
||
config.vm.provider "virtualbox" do |v| | ||
v.memory = 4096 | ||
end | ||
|
||
config.vm.provision "shell", inline: $bootstrap | ||
config.vm.provision "shell", run: "always", inline: $install, privileged: true | ||
config.vm.provision "shell", run: "always", inline: $web_install, privileged: false | ||
config.vm.provision "shell", run: "always", inline: $web_run, privileged: false | ||
end |
Oops, something went wrong.