Security News
GitHub Removes Malicious Pull Requests Targeting Open Source Repositories
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
sinopia_indexing_pipeline
Advanced tools
Sinopia Indexing Pipeline listens for STOMP messages, parses URIs out of messages, retrieves resources from an LDP server, and indexes them into ElasticSearch
This is the repository for the Sinopia Indexing Pipeline. The pipeline is a Node application that listens for messages (sent to a queue via STOMP), and for each message (a W3C Activity Streams message):
The pipeline also includes a bin/reindex
command that will wipe all ElasticSearch indices and reindex Trellis by crawling the tree of resources contained within Trellis.
Note that if the Trellis platform is running in a container, the reindexer will also need to run in a container, else it will fail to resolve Trellis's internal hostname. In that event, run docker-compose run reindexer
instead.
Using docker-compose
, you can spin up containers for Trellis, ActiveMQ, ElasticSearch, Postgres, and the pipeline::
$ docker-compose up pipeline # add -d to run in background
To shut it down and clean up, run:
$ docker-compose down
$ npm run ci
Or, to run the linter and unit tests separately:
$ npm run lint
$ npm test
To run the integration tests, they must be invoked independent of the unit tests:
$ npm run integration
NOTE: The pipeline
docker-compose
service must be running for the integration tests to pass.
We are using CircleCI to run continuous integration. CircleCI invokes the integration tests using a container, which works around inter-container networking constraints in the CI environment. If you prefer to run integration tests in a manner that more closely matches what runs in CI, you can do that via:
$ docker-compose run integration
To create a Trellis container and test integration between the pipeline components, you may do so using a curl incantation like follows:
$ curl -i -X POST -H 'Content-Type: application/ld+json' -H 'Link: <http://www.w3.org/ns/ldp#BasicContainer>; rel="type"' -H "Slug: repository" -d '{ "@context": { "dcterms": "http://purl.org/dc/terms/" }, "@id": "", "dcterms:title": "Repository container" }' http://localhost:8080
See Sinopia Server notes for more Trellis curl
incantations.
For development purposes, you may wish to spin up all the components other than the pipeline if you'll be iterating:
$ docker-compose up -d platform search searchui
And then spin up the pipeline using:
$ npm run dev-start
Note that if you want to view the ElasticSearch index, you can browse to http://localhost:1358/.
The CircleCI build is configured to perform these steps automatically on any successful build on the master
branch. If you need to manually build and push an image, you can do this:
$ docker build -t ld4p/sinopia_indexing_pipeline .
$ docker push ld4p/sinopia_indexing_pipeline
FAQs
Sinopia Indexing Pipeline listens for STOMP messages, parses URIs out of messages, retrieves resources from an LDP server, and indexes them into ElasticSearch
The npm package sinopia_indexing_pipeline receives a total of 0 weekly downloads. As such, sinopia_indexing_pipeline popularity was classified as not popular.
We found that sinopia_indexing_pipeline demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.