All Projects → rm3l → docker-api-graphql

rm3l / docker-api-graphql

Licence: MIT license
GraphQL API wrapper around the Docker Remote API. SpringBoot-based app, written in Kotlin

Programming Languages

kotlin
9241 projects
Dockerfile
14818 projects

Projects that are alternatives of or similar to docker-api-graphql

spring-boot-mongo-docker
Spring Boot, Mongo and Docker. Run all with a single command.
Stars: ✭ 16 (+23.08%)
Mutual labels:  springboot, springframework
Spring Boot In Action
Spring Boot 系列实战合集
Stars: ✭ 4,153 (+31846.15%)
Mutual labels:  springboot, springframework
Spring5Certification
Spring Certification: This repository contains my examples and some best references to prepare the Spring 5 certification
Stars: ✭ 30 (+130.77%)
Mutual labels:  springboot, springframework
Nacos Spring Boot Project
Nacos ECO Project for Spring Boot
Stars: ✭ 508 (+3807.69%)
Mutual labels:  springboot, springframework
Spring Cloud Flycloud
🔥🔥🔥FlyClould 微服务实战项目框架,在该框架中,包括了用 Spring Cloud 构建微服务的一系列基本组件和框架,对于后台服务框架的搭建有很大的参考价值,大家可以参考甚至稍加修改可以直接应用于自己的实际的项目开发中,该项目没有采用Maven进行项目构建,Maven通过xml进行依赖管理,导致整个配置文件太过臃肿,另外灵活性也不是很强,所以我采用Gradle进行项目构建和依赖管理,在FlyTour项目中我们见证了Gradle的强大,通过简单的一些配置就可以轻松的实现组件化的功能。该项目共有11个Module工程。其中10个位微服务工程,这10个微服务工程构成了一个完整的微服务系统,微服务系统包含了8个基础服务,提供了一整套微服务治理功能,他们分别是配置中心module_c…
Stars: ✭ 1,514 (+11546.15%)
Mutual labels:  springboot, springframework
Shopizer
Shopizer java e-commerce software
Stars: ✭ 2,541 (+19446.15%)
Mutual labels:  springboot, springframework
BusinessInfrastructurePlatformGroupVersion
A java web project based on Spring Boot using MySQL, Spring MVC, Hibernate, Spring Data JPA, Query DSL, Lombok, Logback, etc.
Stars: ✭ 90 (+592.31%)
Mutual labels:  springboot, springframework
Springboot
Spring Boot chinese document. Spring Boot 2.1.5 中文文档
Stars: ✭ 703 (+5307.69%)
Mutual labels:  springboot, springframework
Mini Spring
mini-spring是简化版的spring框架,能帮助你快速熟悉spring源码和掌握spring的核心原理。抽取了spring的核心逻辑,代码极度简化,保留spring的核心功能,如IoC和AOP、资源加载器、事件监听器、类型转换、容器扩展点、bean生命周期和作用域、应用上下文等核心功能。
Stars: ✭ 698 (+5269.23%)
Mutual labels:  springboot, springframework
Ssm Demo
🍌Spring+SpringMVC+Mybatis+easyUI实现简单的后台管理系统
Stars: ✭ 1,639 (+12507.69%)
Mutual labels:  springboot, springframework
Springboot Practice
SpringBoot practice
Stars: ✭ 234 (+1700%)
Mutual labels:  springboot, springframework
ff4j-spring-boot-starter-parent
A spring boot starter for FF4J (Feature Flipping For Java)
Stars: ✭ 23 (+76.92%)
Mutual labels:  springboot
springboot-react-blog
使用 springboot 和 react 开发的博客系统
Stars: ✭ 77 (+492.31%)
Mutual labels:  springboot
grpc-apm-spring-boot-starter
Spring boot starter for gRPC framework with Elastic APM
Stars: ✭ 18 (+38.46%)
Mutual labels:  springboot
apollo-express-ts-server-boilerplate
No description or website provided.
Stars: ✭ 29 (+123.08%)
Mutual labels:  graphql-server
NBlog
🍓 Spring Boot + Vue 前后端分离博客系统 https://naccl.top
Stars: ✭ 700 (+5284.62%)
Mutual labels:  springboot
xiaomi-vue-store
基于Vue + SpringBoot实现的前后端分离的仿小米商城项目,包含秒杀模块。
Stars: ✭ 58 (+346.15%)
Mutual labels:  springboot
zkspringboot
ZK - Spring Boot integration
Stars: ✭ 38 (+192.31%)
Mutual labels:  springboot
jsf-primefaces
JSF Primefaces Tutorials
Stars: ✭ 93 (+615.38%)
Mutual labels:  springboot
dgraph graphql go
A GraphQL + Dgraph + Go + HTTP based backend service demo.
Stars: ✭ 49 (+276.92%)
Mutual labels:  graphql-server

Docker API GraphQL

Demo Video

A GraphQL API Server around the Docker Remote API. SpringBoot-based app, written in Kotlin.

Build Workflow License Coverage Status

Docker Stars Docker Pulls


Table of Contents generated with DocToc

Demo Video

Running with Docker

This app can run as a lightweight Docker container.

To use it against a local Docker daemon listening on a local Unix socket:

docker run \
 --name docker-api-graphql \
 -d \
 -p 8080:8080 \
 -v /var/run/docker.sock:/var/run/docker.sock \
 rm3l/docker-api-graphql

Note: the -v /var/run/docker.sock:/var/run/docker.sock option can be used in Linux environments only.

For more sophisticated use cases of Docker daemons accessible over the network (and secured with client certificates):

docker run \
 --name docker-api-graphql \
 -d \
 -p 8080:8080 \
 -e DOCKER_HOST=https://<host>:<port> \
 -v /path/to/my/docker/folder/containing/my/certificates:/etc/docker \
 rm3l/docker-api-graphql

Note: the /path/to/my/docker/folder/containing/my/certificates must be mounted under /etc/docker inside the running container, and must follow the semantics behind the DOCKER_CERT_PATH environment variable

You'll just need to access the port 8080 of the Docker engine where docker-api-graphql is running using your browser.

Deploying this API to manage a Swarm cluster is just as easy ! You can directly deploy it as a service in your Docker cluster:

docker service create \
 --name docker-api-graphql \
 -d \
 --publish 8080:8080 \
 --constraint 'node.role == manager' \
 --mount type=bind,src=//var/run/docker.sock,dst=/var/run/docker.sock \
 rm3l/docker-api-graphql \
 -H unix:///var/run/docker.sock

API Endpoints

/graphiql

This gives you access to a GraphiQL application in your browser, so you can play with the GraphQL API

/graphql

This is the entrypoint for the GraphQL API.

Building from source

You can build docker-api-graphql in the same way as any Gradle project on Git.

However, thanks to the Gradle Wrapper (cf. gradlew and gradlew.bat scripts), you do not need to have Gradle installed on your machine.

  1. Clone the docker-api-graphql repository on your machine:
git clone https://github.com/rm3l/docker-api-graphql && cd docker-api-graphql
  1. Switch to the appropriate branch if needed with git checkout ...
  2. Execute a Gradle build in the directory containing the build.gradle file:
./gradlew build
  1. You will find the WAR artifact under the build/libs directory.

Contributing and Improving docker-api-graphql!

Contributions and issue reporting are more than welcome. So to help out, do feel free to fork this repo and open up a pull request. I'll review and merge your changes as quickly as possible.

You can use GitHub issues to report bugs. However, please make sure your description is clear enough and has sufficient instructions to be able to reproduce the issue.

TODO

  • Map other endpoints of the Docker Remote API, e.g,: Services, Secrets, Tasks, ...
  • GraphQL Mutations
  • GraphQL Subscriptions if possible, especially for Docker events
  • Authentication / Authorization

Open-Source Libraries and Tools

Developed by

LICENSE

The MIT License (MIT)

Copyright (c) 2017 Armel Soro

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].