https://github.com/jessestuart/gatsby-source-docker-hub
Docker Hub stats in your GatsbyJS project. 🚢
https://github.com/jessestuart/gatsby-source-docker-hub
docker-hub gatsby-plugin gatsbyjs graphql jest typescript
Last synced: 6 months ago
JSON representation
Docker Hub stats in your GatsbyJS project. 🚢
- Host: GitHub
- URL: https://github.com/jessestuart/gatsby-source-docker-hub
- Owner: jessestuart
- Created: 2019-07-26T16:26:31.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2022-12-11T04:51:43.000Z (over 3 years ago)
- Last Synced: 2025-08-09T06:43:40.753Z (12 months ago)
- Topics: docker-hub, gatsby-plugin, gatsbyjs, graphql, jest, typescript
- Language: TypeScript
- Homepage: https://www.npmjs.com/package/gatsby-source-docker-hub
- Size: 2.8 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 45
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
gatsby-source-docker-hub
[![CircleCI][circleci-badge]][circleci-link] [![npm][npm-badge]][npm-link]
[![codecov][codecov]][codecov 2]
### What is this?
A simple GatsbyJS source plugin allowing you to easily integrate stats from your
Docker Hub profile in your Gatsby site. Just pass in a Docker Hub username, and
get back your top 30 repos, sorted by pull count. It's as simple as:
```graphql
{
allDockerHubRepo(sort: { order: DESC, fields: pullCount }) {
edges {
node {
architectures
description
lastUpdated
name
pullCount
starCount
}
}
}
}
```
And get back something like the below:
```json
{
"data": {
"allDockerHubRepo": {
"edges": [
{
"node": {
"architectures": [
"amd64",
"arm",
"arm64"
],
"description": "OwnTracks. Multiarch. 👌",
"lastUpdated": "2019-08-13T00:27:34.154761Z",
"name": "owntracks",
"pullCount": 491351,
"starCount": 3
}
},
{
"node": {
"architectures": [
"arm",
"arm64",
"amd64"
],
"description": "Nightly multi-architecture (amd64, arm64, armv7) builds for the Kubernetes Helm tiller service.",
"lastUpdated": "2019-08-13T00:27:56.305902Z",
"name": "tiller",
"pullCount": 376722,
"starCount": 11
}
},
{ "//": "etc." }
]
}
}
```
Note that this includes an array of architectures, for Docker images with
multiarch support (i.e., containing a valid [V2 Manifest, Schema 2][docker]).
Check out a simple proof-of-concept at [`multiar.ch`][multiar] (source code
available [here][github]) 🎉
[circleci-badge]:
https://circleci.com/gh/jessestuart/gatsby-source-docker-hub.svg?style=shield
[codecov]:
https://codecov.io/gh/jessestuart/gatsby-source-docker-hub/branch/master/graph/badge.svg
[circleci-link]: https://circleci.com/gh/jessestuart/gatsby-source-docker-hub
[codecov 2]: https://codecov.io/gh/jessestuart/gatsby-source-docker-hub
[docker]: https://docs.docker.com/registry/spec/manifest-v2-2/
[github]: https://github.com/jessestuart/multiar.ch
[multiar]: https://multiar.ch
[npm-badge]: https://img.shields.io/npm/v/gatsby-source-docker-hub.svg
[npm-link]: https://www.npmjs.com/package/gatsby-source-docker-hub