Skip to content
This repository has been archived by the owner on Dec 8, 2022. It is now read-only.

Consider sharing entrypoint.sh script with other continuous integration solutions #10

Open
nicorikken opened this issue Jul 15, 2021 · 2 comments

Comments

@nicorikken
Copy link
Member

nicorikken commented Jul 15, 2021

There is a potential of reusing the entrypoint.sh for other container-based continuous integration solutions. The entrypoint.sh script could be adopted in the main ORT repository so it is included in all Docker containers and can be referenced by using it as the entrypoint. Or it can just be copied over to each relevant continuous integration solution repository.

@nicorikken
Copy link
Member Author

nicorikken commented Aug 3, 2021

Currently the default values are set in the github action but not in the entrypoint, resulting in an error when running a container with entrypoint without values:

+ [[ 0 -gt 0 ]]
+ mkdir -p ort/reports
+ mkdir -p ort/results
+ /opt/ort/bin/ort --info analyze -i . -o ort --package-curations-file curations.yml
15:31:42.634 [main] INFO  org.ossreviewtoolkit.model.config.LicenseFilenamePatterns - Configuring the license file patterns.
________ _____________________
\_____  \\______   \__    ___/ the OSS Review Toolkit, version DOCKER-SNAPSHOT.
 /   |   \|       _/ |    |
/    |    \    |   \ |    |    Running 'analyze' under Java 11.0.8 on Linux with
\_______  /____|_  / |____|    8 CPUs and a maximum of 3966 MiB of memory.
        \/       \/
Environment variables:
ORT_CONFIG_DIR = /root/.ort/config
ORT_DATA_DIR = /root/.ort
JAVA_HOME = /opt/java/openjdk
ANDROID_HOME = /opt/android-sdk
GOPATH = /go

Usage: ort analyze [OPTIONS]

Error: Invalid value for "--package-curations-file": File "curations.yml" does not exist.
+ LAST_OUTPUT_FILE=ort/analyzer-result.yml
+ cp ort/analyzer-result.yml ort/results/
cp: cannot stat 'ort/analyzer-result.yml': No such file or directory
+ ''
/entrypoint.sh: line 66: : command not found
+ ''
/entrypoint.sh: line 76: : command not found
+ ''
/entrypoint.sh: line 87: : command not found
+ ''
/entrypoint.sh: line 103: : command not found

@nicorikken
Copy link
Member Author

A separate issue #19 for setting the default values

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant