Closed mpsonntag closed 3 years ago
Changes Missing Coverage | Covered Lines | Changed/Added Lines | % | ||
---|---|---|---|---|---|
cmd/gindoid/config.go | 0 | 1 | 0.0% | ||
cmd/gindoid/dataset.go | 36 | 81 | 44.44% | ||
<!-- | Total: | 48 | 94 | 51.06% | --> |
Files with Coverage Reduction | New Missed Lines | % | ||
---|---|---|---|---|
cmd/gindoid/dataset.go | 1 | 12.71% | ||
<!-- | Total: | 1 | --> |
Totals | |
---|---|
Change from base Build 554380259: | 3.6% |
Covered Lines: | 207 |
Relevant Lines: | 1673 |
This PR introduces the following major and minor changes:
Changes in the DOI registration procedure
doienv
environmental variables config file. The specific variable name ispreparation
..git
folder from the zip file. ThederepoCloneDir
function has been removed from the registration procedure. This leaves the cloned repository intact in thepreparation
directory on the host machine and can be used for manual registration steps e.g. upload of annexed data to the DOI fork of the repository.Dockerfile
also supports the newly introducedpreparation
folder.Removing the application freeze on git annex uninit
The removal of the
derepoCloneDir
resolves the issue of very large datasets freezing the registration process on thegit annex uninit
step. For details see issue #78. It is still unclear why the application freeze had happened, but tests with repositories that consistently froze the service in multiple test runs now succeed without any issues.Providing the '/assets' content to a docker host
The DOI registration service and the static DOI hosting service both use the same 'assets'. Until now the assets from
/assets
had to be manually copied to the DOI hosting service when changes to the assets were made after deploying a new version of the DOI registration service. The PR introduces adocker_startup.sh
shell script as a new entrypoint for Docker deployment. This script copies the content of the 'assets' folder to the/doidata
volume after the docker container has been started. This ensures, that the host, that is using the/doidata
volume to statically provide registered DOI datasets, now automatically has access to the same 'assets' as the DOI registration service. Closes #85.Minor changes
zip
function has been renamed torunzip
to avoid any potential name clashes with the standard library packagearchive/zip
.MakeZip
function is copied from the 'G-Node/libgin' library, since it is only used by gin-doi and none of the other gin libraries; it is also unlikely that it will be used by another gin library. The code added also includes a basic test.