File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 33 - planetpython.org
44 - www.planetpython.org
55 sites:
6- planetpython.org :
6+ planetpython:
7+ cache: /srv/cache/
8+ output: /srv/planetpython.org/
9+ image: ghcr.io/python/planetpython:latest
10+ config: config.ini
11+ planetpython-3 :
12+ cache: /srv/cache3/
13+ output: /srv/planetpython.org/3/
14+ image: ghcr.io/python/planetpython-3:latest
715 config: config.ini
Original file line number Diff line number Diff line change 11cd /srv/planet/
22git pull
3- {% for site in salt ["pillar.get" ]("planet" , {}).get ("sites" ).values () %}
4- $(which python2.7) /srv/planet/code/planet.py /srv/planet/config/{{ site["config"] }}
3+ {% for site , site_config in salt ["pillar.get" ]("planet" , {}).get ("sites" ).items () %}
4+ docker run --rm -it \
5+ -v {{ site_config["cache"] }}:/srv/cache/ \
6+ -v {{ site_config["output"] }}:/srv/planetpython.org/ \
7+ -v /srv/planet/config/{{ site_config["config"] }}:/planet/config/config.ini \
8+ {{ site_config["image"] }} \
9+ python /planet/code/planet.py /planet/config/config.ini
510{% endfor %}
Original file line number Diff line number Diff line change @@ -4,10 +4,20 @@ include:
44git:
55 pkg.installed
66
7+ docker.io :
8+ pkg.installed
9+ docker:
10+ service.running :
11+ - enable: True
12+
713planet-user :
814 user.present :
915 - name: planet
1016 - createhome: False
17+ - groups:
18+ - docker
19+ - require:
20+ - pkg: docker.io
1121
1222/etc/nginx/sites.d/planet.conf :
1323 file.managed :
@@ -40,7 +50,7 @@ planet-user:
4050
4151https: //github.com/python/planet:
4252 git.latest :
43- - branch: py2
53+ - branch: main
4454 - target: /srv/planet/
4555 - user: planet
4656 - require:
You can’t perform that action at this time.
0 commit comments