mirror of
https://github.com/retspen/webvirtcloud
synced 2026-12-02 08:56:07 +00:00
fix(docker): the settings.py kept next to the compose file stays out of the image
The README has Docker users keep their own settings.py next to the compose file and mount it. .dockerignore left out only webvirtcloud/settings.py, so the next docker compose build copied that file, with its LDAP password or SECRET_KEY, into an image layer. It is now ignored by Docker and git, and CI plants it among the files that must not reach the image.
This commit is contained in:
parent
ed1b746b77
commit
ad5b515e9d
3 changed files with 5 additions and 2 deletions
|
|
@ -14,6 +14,8 @@ backups
|
|||
**/console/cert.pem*
|
||||
**/dhcpd.*
|
||||
webvirtcloud/settings.py
|
||||
# the copy the README has Docker users keep next to the compose file
|
||||
settings.py
|
||||
**/staticfiles
|
||||
|
||||
# virtualenvs, caches and editor files
|
||||
|
|
|
|||
4
.github/workflows/test.yml
vendored
4
.github/workflows/test.yml
vendored
|
|
@ -152,7 +152,7 @@ jobs:
|
|||
- name: Plant Secret Sentinels
|
||||
run: |
|
||||
mkdir -p data
|
||||
for f in data/secret_key data/admin_password webvirtcloud/settings.py.bak \
|
||||
for f in data/secret_key data/admin_password settings.py webvirtcloud/settings.py.bak \
|
||||
'webvirtcloud/settings.py~' webvirtcloud/.settings.py.swp; do
|
||||
echo sentinel > "$f"
|
||||
done
|
||||
|
|
@ -175,7 +175,7 @@ jobs:
|
|||
run: |
|
||||
docker run --rm --entrypoint sh webvirtcloud:ci -c '
|
||||
cd /srv/webvirtcloud
|
||||
for f in data/secret_key data/admin_password webvirtcloud/settings.py.bak \
|
||||
for f in data/secret_key data/admin_password settings.py webvirtcloud/settings.py.bak \
|
||||
"webvirtcloud/settings.py~" webvirtcloud/.settings.py.swp; do
|
||||
if [ -e "$f" ]; then echo "$f is in the image"; exit 1; fi
|
||||
done'
|
||||
|
|
|
|||
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -13,6 +13,7 @@ console/cert.pem*
|
|||
tags
|
||||
dhcpd.*
|
||||
webvirtcloud/settings.py
|
||||
/settings.py
|
||||
.coverage
|
||||
htmlcov
|
||||
*.log
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue