-
-
Couldn't load subscription status.
- Fork 118
Add script for D2D with SCIO using docker container #1912
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
Conversation
Signed-off-by: Tushar Goel <tushar.goel.dav@gmail.com>
Output with the following script. |
|
For simplicity and safety, I would consider using Docker compose to handle the database service. You can create a new docker-compose.yml that has scanpipe and the database, something along the lines of: You can run scanpipe commands by doing |
|
|
I agree with @JonoYang, we do not want to re-invent orchestration here. Also, in case of a simple one-off pipeline run, what about using the dedicated
The Running it would looks somthing like this: |
|
When I use above docker compose file with run command, I get this error. |
|
@TG1999 #1916 merged and released https://github.com/aboutcode-org/scancode.io/releases/tag/v35.4.1 Documented at https://scancodeio.readthedocs.io/en/latest/quickstart.html#use-postgresql-for-better-performance Pull the latest ScanCode.io Docker imageStart a PostgreSQL Database ServiceStop the service with Run the
|
42737c6 to
f6699d7
Compare
Signed-off-by: Tushar Goel <tushar.goel.dav@gmail.com>
744af1c to
79f49d8
Compare
etc/scripts/d2d/README.rst
Outdated
|
|
||
| .. code-block:: bash | ||
| ./run_mapping.sh ./from.tar.gz ./to.whl "" results.txt false |
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.
Having to provide "" for the options when empty is not ideal.
Option should be passed as an an option --options OPTIONS arg.
Same for false, this should be an option --spin-db.
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.
So how the options shall be passed then ?
--option Python --option Java
or
--option "Python,Java"
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.
I have pushed with --options "Python,Java" for now. Please check
Signed-off-by: Tushar Goel <tushar.goel.dav@gmail.com>
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.
Last minor change request, we should be ready to merged after this one.
Signed-off-by: Tushar Goel <tushar.goel.dav@gmail.com>
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.
@TG1999 sorry about the late review, here are some doc improvement suggestions for your consideration. These can be addressed separately.
| +-----------------+-------------------------------------------------------------+ | ||
| | Argument | Description | | ||
| +=================+=============================================================+ | ||
| | ``from-path`` | Path to the base deployment/scan file | |
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.
here from and to sides should be more closely aligned with the explanation we have at https://github.com/aboutcode-org/scancode.io/blob/main/scanpipe/pipelines/deploy_to_develop.py#L42 so it is clear that one is the source side and the other is the deployed side. The base/target names used here is new and a tad bit confusing.
| +-----------------+-------------------------------------------------------------+ | ||
| | ``to-path`` | Path to the target deployment/scan file | | ||
| +-----------------+-------------------------------------------------------------+ | ||
| | ``options`` | D2D pipeline parameters (can be empty ``""``) | |
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.
options should also be a bit more descriptive, to communicate that these are ecosystem specific optional steps, and instead of can be empty we can probably mention in someway which parameters are optional and which are required.
We should probably also have a reference page on all the supported ecosystems in d2d and the capabilities supported there, and link to this page. I opened a seperate issue for this: #1922
| Run ScanCode.io Mapping Script | ||
| ================================ | ||
|
|
||
| This script executes the ``map_deploy_to_develop`` mapping workflow from |
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.
Insert a RST link to https://github.com/aboutcode-org/scancode.io/blob/main/docs/built-in-pipelines.rst?plain=1#L188, cross links between related docummention pages are always useful.
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.
Maybe a short description of d2d (similar to the pipeline docstring) would also be useful?
Closes:
Related: