Page MenuHomeDevCentral

Usee Docker pillar information in nginx config
Changes PlannedPublic

Authored by dereckson on Oct 28 2019, 03:13.
Tags
None
Referenced Files
F52618033: D2084.diff
Sat, Oct 3, 15:06
F52592693: D2084.id5250.diff
Sat, Oct 3, 11:43
F52574655: D2084.id5260.diff
Sat, Oct 3, 09:39
F52574650: D2084.id5249.diff
Sat, Oct 3, 09:39
F52568948: D2084.id5250.diff
Sat, Oct 3, 09:00
F52563823: D2084.id10512.diff
Sat, Oct 3, 08:20
F52563820: D2084.id10516.diff
Sat, Oct 3, 08:20
Unknown Object (File)
Thu, Oct 1, 06:22
Subscribers
None

Details

Reviewers
dereckson
Summary

Initially, the nginx configuration for the Alkane webserver role
used hardcoded port information to pass a request to Docker PaaS.

This change introduces a method to prepare a dictionary of proxy_pass URLs
per server and application, and applies it for API and infra.

Meanwhile, another change introduced a services table, but this change
allows to automatically handle host and port changes.

Test Plan

Deploy on Ysul

Diff Detail

Repository
rOPS Nasqueron Operations
Lint
Lint Passed
SeverityLocationCodeMessage
Advice_modules/paas_docker.py:138F821flake8 F821
Advice_modules/paas_docker.py:141F821flake8 F821
Unit
No Test Coverage
Branch
configure-docker-upstreams
Build Status
Buildable 6525
Build 6809: arc lint + arc unit

Event Timeline

dereckson created this revision.

Remove debug information, use correct pillar syntax.

Call paas_docker.get_upstreams()

This change is interesting and should be rebased.

Rebased against current main for Alkane.

dereckson retitled this revision from WIP: Use Docker pillar information in nginx config to Usee Docker pillar information in nginx config.Mar 23 2026, 14:04

Next: try salt web-001 paas_docker.get_upstreams

Rebased. Fixed pillar handling.

The output is really useful to avoid to manually repeat the ports.

But since salt-tower, we can't have a view from web-001 on the docker-002 pillar.

For example, if we run paas_docker.get_upstreams against docker-002, we've this dictionary:

{P396}


So, if we want to adopt this system, there is a need to consolidate the salt-tower files, by recreating the former unified pillar.

I've asked upstream for advice how to resolve pillar for another server than the current node @ https://groups.google.com/g/salt-tower/c/XEKg2CEiZrU