Files
faas/docker-compose.armhf.yml
John McCabe bc16d125bf Lock down Prometheus Alertmanager and NATS ports by default (#378)
* Stop exposing Alertmanager and NATS ports

This commit stops exposing the Prometheus Alertmanager and NATS ports by
default on Swarm.

The respective sections are commented out with a note on re-enabling
them.

Signed-off-by: John McCabe <john@johnmccabe.net>

* Revert queue-worker dev tag in yaml

Signed-off-by: John McCabe <john@johnmccabe.net>
2017-11-30 01:05:09 +01:00

101 lines
2.8 KiB
YAML
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

version: "3"
services:
# Core API services are pinned, HA is provided for functions.
gateway:
volumes:
- "/var/run/docker.sock:/var/run/docker.sock"
ports:
- 8080:8080
image: functions/gateway:0.6.9-armhf
networks:
- functions
environment:
read_timeout: 10 # set both here, and on your functions
write_timeout: 10 # set both here, and on your functions
deploy:
placement:
constraints: [node.role == manager]
prometheus:
image: alexellis2/prometheus-armhf:1.5.2
volumes:
- ./prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
- ./prometheus/alert.rules:/etc/prometheus/alert.rules
command: "-config.file=/etc/prometheus/prometheus.yml -storage.local.path=/prometheus -storage.local.memory-chunks=10000 --alertmanager.url=http://alertmanager:9093"
ports:
- 9090:9090
environment:
no_proxy: "gateway"
networks:
- functions
deploy:
placement:
constraints: [node.role == manager]
alertmanager:
image: alexellis2/alertmanager-armhf:0.5.1
environment:
no_proxy: "gateway"
volumes:
- ./prometheus/alertmanager.yml:/alertmanager.yml
command:
- '-config.file=/alertmanager.yml'
networks:
- functions
# Uncomment the following port mapping if you wish to expose the Prometheus
# Alertmanager UI.
# ports:
# - 9093:9093
deploy:
placement:
constraints: [node.role == manager]
# sample functions go here, but can be created in the UI too.
nodeinfo:
image: functions/nodeinfo:latest-armhf
labels:
function: "true"
networks:
- functions
environment:
no_proxy: "gateway"
https_proxy: $https_proxy
markdown:
image: functions/markdownrender:latest-armhf
labels:
function: "true"
networks:
- functions
environment:
no_proxy: "gateway"
https_proxy: $https_proxy
wordcount:
image: functions/alpine:latest-armhf
labels:
function: "true"
networks:
- functions
environment:
fprocess: "wc"
no_proxy: "gateway"
https_proxy: $https_proxy
echoit:
image: functions/alpine:latest-armhf
labels:
function: "true"
networks:
- functions
environment:
fprocess: "cat"
no_proxy: "gateway"
https_proxy: $https_proxy
networks:
functions:
driver: overlay