mirror of
https://github.com/pomerium/pomerium.git
synced 2025-05-23 05:57:19 +02:00
62 lines
1.4 KiB
Jsonnet
62 lines
1.4 KiB
Jsonnet
local utils = import '../utils.libsonnet';
|
|
|
|
function() {
|
|
local name = 'fortio',
|
|
local image = 'fortio/fortio:1.17.0',
|
|
|
|
compose: {
|
|
services:
|
|
utils.ComposeService(name, {
|
|
image: image,
|
|
depends_on: {
|
|
[name + '-init']: {
|
|
condition: 'service_completed_successfully',
|
|
},
|
|
},
|
|
command: [
|
|
'server',
|
|
'-cert',
|
|
'/fortio_config/trusted.pem',
|
|
'-key',
|
|
'/fortio_config/trusted-key.pem',
|
|
],
|
|
ports: [
|
|
'8079:8079/tcp',
|
|
],
|
|
volumes: [
|
|
'fortio_config:/fortio_config',
|
|
],
|
|
}) +
|
|
utils.ComposeService(name + '-init', {
|
|
image: 'busybox:latest',
|
|
command: [
|
|
'sh',
|
|
'-c',
|
|
|||
|
|
echo "$$CERT" >/fortio_config/trusted.pem
|
|
echo "$$KEY" >/fortio_config/trusted-key.pem
|
|
|||,
|
|
],
|
|
environment: {
|
|
CERT: importstr '../files/trusted.pem',
|
|
KEY: importstr '../files/trusted-key.pem',
|
|
},
|
|
volumes: [
|
|
'fortio_config:/fortio_config',
|
|
],
|
|
}) +
|
|
utils.ComposeService(name + '-ready', {
|
|
image: 'jwilder/dockerize:0.6.1',
|
|
command: [
|
|
'-wait',
|
|
'http://' + name + ':8080',
|
|
'-timeout',
|
|
'10m',
|
|
],
|
|
}),
|
|
volumes: {
|
|
fortio_config: {},
|
|
},
|
|
},
|
|
kubernetes: [],
|
|
}
|