All Projects → eBayClassifiedsGroup → Panteras

eBayClassifiedsGroup / Panteras

Licence: gpl-2.0
PanteraS - PaaS - Platform as a Service in a box

Programming Languages

shell
77523 projects

Projects that are alternatives of or similar to Panteras

xxcloud
xxcloud,旨在整合数据中心异构虚拟化资源为统一的资源池,并在资源池上为用户提供各类IAAS、PAAS服务。
Stars: ✭ 64 (-66.14%)
Mutual labels:  paas, marathon, mesos
Marathon Consul
Integrates Marathon apps with Consul service discovery.
Stars: ✭ 174 (-7.94%)
Mutual labels:  marathon, consul, mesos
consul-registration-hook
Hook that can be used for synchronous registration and deregistration in Consul discovery service on Kubernetes or Mesos cluster with Allegro executor
Stars: ✭ 17 (-91.01%)
Mutual labels:  consul, marathon, mesos
Traefik
The Cloud Native Application Proxy
Stars: ✭ 36,089 (+18994.71%)
Mutual labels:  marathon, consul, mesos
micro-service-practice
OpenStack+Docker+RestAPI+OAuth/HMAC+RabbitMQ/ZMQ+OpenResty/HAProxy/Nginx/APIGateway+Bootstrap/AngularJS+Ansible+K8S/Mesos/Marathon构建/探索微服务最佳实践。
Stars: ✭ 25 (-86.77%)
Mutual labels:  marathon, mesos, haproxy
My Cheat Sheets
A place to keep all my cheat sheets for the complete development of ASIC/FPGA hardware or a software app/service.
Stars: ✭ 94 (-50.26%)
Mutual labels:  marathon, consul, mesos
Marathon Lb
Marathon-lb is a service discovery & load balancing tool for DC/OS
Stars: ✭ 449 (+137.57%)
Mutual labels:  marathon, mesos, haproxy
Paasta
An open, distributed platform as a service
Stars: ✭ 1,569 (+730.16%)
Mutual labels:  paas, marathon, mesos
sbt-marathon
An sbt plugin for launching application containers on the Mesosphere Marathon platform.
Stars: ✭ 23 (-87.83%)
Mutual labels:  marathon, mesos
dcos-deploy
Deploy, manage and orchestrate services and apps on DC/OS
Stars: ✭ 21 (-88.89%)
Mutual labels:  marathon, mesos
dcos-autoscaler
Autoscaler for DC/OS hosted in a cloud provider
Stars: ✭ 12 (-93.65%)
Mutual labels:  marathon, mesos
letsencrypt-dcos
Let's Encrypt DC/OS!
Stars: ✭ 39 (-79.37%)
Mutual labels:  marathon, haproxy
Nixy
nixy - nginx auto configuration and service discovery for Mesos/Marathon
Stars: ✭ 259 (+37.04%)
Mutual labels:  marathon, mesos
Patroni
A template for PostgreSQL High Availability with Etcd, Consul, ZooKeeper, or Kubernetes
Stars: ✭ 4,434 (+2246.03%)
Mutual labels:  consul, haproxy
Swan
A Distributed, Highly Available Mesos Scheduler, Inspired by the design of Google Borg
Stars: ✭ 411 (+117.46%)
Mutual labels:  marathon, mesos
mesos-executor
Customizable Apache Mesos task executor
Stars: ✭ 50 (-73.54%)
Mutual labels:  consul, mesos
resty-marathon-lb
基于 OpenResty 的 Marathon 服务发现 & 路由
Stars: ✭ 13 (-93.12%)
Mutual labels:  marathon, mesos
spring-cloud-marathon
Spring Cloud integration with Mesos and Marathon
Stars: ✭ 29 (-84.66%)
Mutual labels:  marathon, mesos
marathon-slack
Integration for Marathon's Event Bus with Slack
Stars: ✭ 42 (-77.78%)
Mutual labels:  marathon, mesos
Linkerdcosdockerfile
Linker Dcos DockerFile&DockerCompose yml file
Stars: ✭ 8 (-95.77%)
Mutual labels:  marathon, mesos

Build Status Docker Hub Current Release

PanteraS
entire Platform as a Service, in a box

"One container to rule them all"

Now you can create a completely dockerized environment for a platform as a service (PaaS) in no time!
PanteraS contains all the necessary components for a highly robust, highly available, fault tolerant PaaS.
The goal is to spawn fully scalable, easy to monitor, debug and orchestrate services in seconds. Totally independent of the underlying infrastructure. PanteraS is also fully transferable between development stages. You can run it on your laptop, test and production systems without hassle.

"You shall not PaaS"

Architecture

Components

  • Mesos + Marathon + ZooKeeper (orchestration components)
  • Consul (K/V store, monitoring, service directory and registry) + Registrator (automating register/ deregister)
  • Fabio (load balancer with dynamic config generation)

PanteraS Architecture

Master+Slave mode Container

This is the default configuration. It will start all components inside a container.
It is recommended to run 3 master containers to ensure high availability of the PasteraS cluster.

Master Mode

Only Slave mode Container

Slave mode is enabled by MASTER=false
In this mode only slave components will start (master part is excluded). You can run as many slaves as you wish - this is fully scalable.

Slave Mode

Multiple Datacenter supported by Consul

To connect multiple datacenters use consul join -wan <server 1> <server 2>

Consul multi DC

Combination of daemons startup

Depending on MASTER and SLAVE you can define role of the container

daemon\role default Only Master Only Slave
. MASTER=true MASTER=true MASTER=false
. SLAVE=true SLAVE=false SLAVE=true
Consul x x x
Mesos Master x x -
Marathon x x -
Zookeeper x x -
Mesos Slave x - x
Registrator x - x
Fabio x - x
Traefik - - x
Netdata - - -

Optional services (disabled by default) require manual override like START_TRAEFIK=true

Requirements:

  • docker >= 1.12
  • docker-compose >= 1.8.0

Usage:

Clone it

git clone -b 0.4.3 https://github.com/eBayClassifiedsGroup/PanteraS.git
cd PanteraS

Default: Stand alone mode

(master and slave in one box)

# vagrant up

or

# IP=<DOCKER_HOST_IP> ./generate_yml.sh
# docker-compose up -d

3 Masters + N slaves:

Configure zookeeper and consul:

everyhost# mkdir restricted
everyhost# echo 'ZOOKEEPER_HOSTS="masterhost-1:2181,masterhost-2:2181,masterhost-3:2181"' >> restricted/host
everyhost# echo 'CONSUL_HOSTS="-join=masterhost-1 -join=masterhost-2 -join=masterhost-3"' >> restricted/host
everyhost# echo 'MESOS_MASTER_QUORUM=2' >> restricted/host

Lets set only masterhost-1 to bootstrap the consul

masterhost-1# echo 'CONSUL_PARAMS="-bootstrap-expect 3"' >> restricted/host
masterhost-1# echo 'ZOOKEEPER_ID=1' >> restricted/host
masterhost-2# echo 'ZOOKEEPER_ID=2' >> restricted/host
masterhost-3# echo 'ZOOKEEPER_ID=3' >> restricted/host

Optionally, if you have multiple IPs, set an IP address of docker host (do not use docker0 interface IP)
if you don't set it - it will try to guess dig +short ${HOSTNAME}

masterhost-1# echo 'IP=x.x.x.1' >> restricted/host
masterhost-2# echo 'IP=x.x.x.2' >> restricted/host
masterhost-3# echo 'IP=x.x.x.3' >> restricted/host
Start containers:
masterhost-n# ./generate_yml.sh
masterhost-n# docker-compose up -d
slavehost-n# MASTER=false ./generate_yml.sh
slavehost-n# docker-compose up -d

Web Interfaces

You can reach the PaaS components on the following ports:

Listening address

All PaaS components listen default on all interfaces (to all addresses: 0.0.0.0),
which might be dangerous if you want to expose the PaaS.
Use ENV LISTEN_IP if you want to listen on specific IP address.
for example:
echo LISTEN_IP=192.168.10.10 >> restricted/host
This might not work for all services like Marathon that has some additional random ports.

Services Accessibility

You might want to access the PaaS and services with your browser directly via service name like:

http://your_service.service.consul

This could be problematic. It depends where you run docker host. We have prepared two services that might help you solving this problem.

DNS - which supposed to be running on every docker host, it is important that you have only one DNS server occupying port 53 on docker host, you might need to disable yours, if you have already configured.

If you have direct access to the docker host DNS, then just modify your /etc/resolv.conf adding its IP address.

If you do NOT have direct access to docker host DNS, you can use SSHuttle project
so you can tunnel DNS traffic over ssh

Running an example application

There are two examples available:
SimpleWebappPython - basic example - spawn 2x2 containers
SmoothWebappPython - similar to previous one, but with smooth scaling down

Fabio will balance the ports which where mapped and assigned by marathon.

For non human access like services intercommunication, you can use direct access using DNS consul SRV abilities, to verify answers:

$ dig python.service.consul +tcp SRV

or ask consul DNS directly:

$ dig @$CONSUL_IP -p8600  python.service.consul +tcp SRV

Deploy using marathon_deploy

You can deploy your services using marathon_deploy, which also understand YAML and JSON files. As a benefit, you can have static part in YAML deployment plans, and dynamic part (like version or URL) set with ENV variables, specified with %%MACROS%% in deployment plan.

apt-get install ruby1.9.1-dev
gem install marathon_deploy

more info: https://github.com/eBayClassifiedsGroup/marathon_deploy

References

[1] https://www.docker.com/
[2] http://docs.docker.com/compose/
[3] http://stackoverflow.com/questions/25217208/setting-up-a-docker-fig-mesos-environment
[4] http://www.consul.io/docs/

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].