Skip to content

Commit bed345e

Browse files
author
pixelead0
committed
chore(config): agregar configuración base, licencias y MkDocs (gitignore, LICENSE, Docker, mkdocs.yml, requirements.txt)
1 parent 913b283 commit bed345e

File tree

8 files changed

+738
-0
lines changed

8 files changed

+738
-0
lines changed

.dockerignore

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
# Git
2+
.git
3+
.gitignore
4+
.gitattributes
5+
6+
# Documentation
7+
README.md
8+
CONTRIBUTING.md
9+
CODE_OF_CONDUCT.md
10+
SECURITY.md
11+
CHANGELOG.md
12+
LICENSE
13+
14+
# Python
15+
__pycache__/
16+
*.py[cod]
17+
*$py.class
18+
*.so
19+
.Python
20+
build/
21+
develop-eggs/
22+
dist/
23+
downloads/
24+
eggs/
25+
.eggs/
26+
lib/
27+
lib64/
28+
parts/
29+
sdist/
30+
var/
31+
wheels/
32+
share/python-wheels/
33+
*.egg-info/
34+
.installed.cfg
35+
*.egg
36+
MANIFEST
37+
38+
# Virtual environments
39+
.env
40+
.venv
41+
env/
42+
venv/
43+
ENV/
44+
env.bak/
45+
venv.bak/
46+
47+
# IDE
48+
.vscode/
49+
.idea/
50+
*.swp
51+
*.swo
52+
*~
53+
54+
# OS
55+
.DS_Store
56+
.DS_Store?
57+
._*
58+
.Spotlight-V100
59+
.Trashes
60+
ehthumbs.db
61+
Thumbs.db
62+
63+
# MkDocs
64+
site/
65+
.mypy_cache/
66+
.dmypy.json
67+
dmypy.json
68+
69+
# Logs
70+
*.log
71+
logs/
72+
73+
# Temporary files
74+
*.tmp
75+
*.temp
76+
77+
# Docker
78+
Dockerfile
79+
.dockerignore
80+
docker-compose.yml
81+
docker-compose.*.yml
82+
83+
# GitHub
84+
.github/
85+
86+
# Local development
87+
*.local
88+
local_settings.py

.gitignore

Lines changed: 215 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,215 @@
1+
# Byte-compiled / optimized / DLL files
2+
__pycache__/
3+
*.py[cod]
4+
*$py.class
5+
6+
# C extensions
7+
*.so
8+
9+
# Distribution / packaging
10+
.Python
11+
build/
12+
develop-eggs/
13+
dist/
14+
downloads/
15+
eggs/
16+
.eggs/
17+
lib/
18+
lib64/
19+
parts/
20+
sdist/
21+
var/
22+
wheels/
23+
share/python-wheels/
24+
*.egg-info/
25+
.installed.cfg
26+
*.egg
27+
MANIFEST
28+
29+
# PyInstaller
30+
# Usually these files are written by a python script from a template
31+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
32+
*.manifest
33+
*.spec
34+
35+
# Installer logs
36+
pip-log.txt
37+
pip-delete-this-directory.txt
38+
39+
# Unit test / coverage reports
40+
htmlcov/
41+
.tox/
42+
.nox/
43+
.coverage
44+
.coverage.*
45+
.cache
46+
nosetests.xml
47+
coverage.xml
48+
*.cover
49+
*.py,cover
50+
.hypothesis/
51+
.pytest_cache/
52+
cover/
53+
54+
# Translations
55+
*.mo
56+
*.pot
57+
58+
# Django stuff:
59+
*.log
60+
local_settings.py
61+
db.sqlite3
62+
db.sqlite3-journal
63+
64+
# Flask stuff:
65+
instance/
66+
.webassets-cache
67+
68+
# Scrapy stuff:
69+
.scrapy
70+
71+
# Sphinx documentation
72+
docs/_build/
73+
74+
# PyBuilder
75+
.pybuilder/
76+
target/
77+
78+
# Jupyter Notebook
79+
.ipynb_checkpoints
80+
81+
# IPython
82+
profile_default/
83+
ipython_config.py
84+
85+
# pyenv
86+
# For a library or package, you might want to ignore these files since the code is
87+
# intended to run in multiple environments; otherwise, check them in:
88+
# .python-version
89+
90+
# pipenv
91+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
92+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
93+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
94+
# install all needed dependencies.
95+
#Pipfile.lock
96+
97+
# poetry
98+
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
99+
# This is especially recommended for binary packages to ensure reproducibility, and is more
100+
# commonly ignored for libraries.
101+
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
102+
#poetry.lock
103+
104+
# pdm
105+
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
106+
#pdm.lock
107+
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
108+
# in version control.
109+
# https://pdm.fming.dev/#use-with-ide
110+
.pdm.toml
111+
112+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
113+
__pypackages__/
114+
115+
# Celery stuff
116+
celerybeat-schedule
117+
celerybeat.pid
118+
119+
# SageMath parsed files
120+
*.sage.py
121+
122+
# Environments
123+
.env
124+
.venv
125+
env/
126+
venv/
127+
ENV/
128+
env.bak/
129+
venv.bak/
130+
131+
# Spyder project settings
132+
.spyderproject
133+
.spyproject
134+
135+
# Rope project settings
136+
.ropeproject
137+
138+
# mkdocs
139+
site/
140+
141+
# mypy
142+
.mypy_cache/
143+
.dmypy.json
144+
dmypy.json
145+
146+
# Pyre type checker
147+
.pyre/
148+
149+
# pytype static type analyzer
150+
.pytype/
151+
152+
# Cython debug symbols
153+
cython_debug/
154+
155+
# PyCharm
156+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
157+
# be added to the global gitignore or merged into this project gitignore. For a PyCharm
158+
# project, it is recommended to include the following files:
159+
# .idea/
160+
# *.iml
161+
# *.ipr
162+
# *.iws
163+
164+
# VS Code
165+
.vscode/
166+
167+
# macOS
168+
.DS_Store
169+
.AppleDouble
170+
.LSOverride
171+
172+
# Windows
173+
Thumbs.db
174+
ehthumbs.db
175+
Desktop.ini
176+
177+
# Linux
178+
*~
179+
180+
# Temporary files
181+
*.tmp
182+
*.temp
183+
*.swp
184+
*.swo
185+
*~
186+
187+
# Logs
188+
*.log
189+
logs/
190+
191+
# Database
192+
*.db
193+
*.sqlite
194+
*.sqlite3
195+
196+
# Backup files
197+
*.bak
198+
*.backup
199+
200+
# IDE specific files
201+
.idea/
202+
*.iml
203+
*.ipr
204+
*.iws
205+
.vscode/
206+
*.code-workspace
207+
208+
# OS generated files
209+
.DS_Store
210+
.DS_Store?
211+
._*
212+
.Spotlight-V100
213+
.Trashes
214+
ehthumbs.db
215+
Thumbs.db

Dockerfile

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
# Dockerfile para Python CDMX Charlas
2+
# Basado en Python 3.11 slim para optimizar el tamaño
3+
4+
FROM python:3.11-slim
5+
6+
# Establecer variables de entorno
7+
ENV PYTHONUNBUFFERED=1 \
8+
PYTHONDONTWRITEBYTECODE=1 \
9+
PIP_NO_CACHE_DIR=1 \
10+
PIP_DISABLE_PIP_VERSION_CHECK=1
11+
12+
# Instalar dependencias del sistema
13+
RUN apt-get update \
14+
&& apt-get install -y --no-install-recommends \
15+
git \
16+
curl \
17+
build-essential \
18+
&& rm -rf /var/lib/apt/lists/*
19+
20+
# Crear usuario no-root para seguridad
21+
RUN groupadd -r mkdocs && useradd -r -g mkdocs mkdocs
22+
23+
# Establecer directorio de trabajo
24+
WORKDIR /app
25+
26+
# Copiar archivos de dependencias
27+
COPY requirements.txt .
28+
29+
# Instalar dependencias de Python
30+
RUN pip install --no-cache-dir -r requirements.txt
31+
32+
# Copiar código fuente
33+
COPY . .
34+
35+
# Cambiar propietario de archivos
36+
RUN chown -R mkdocs:mkdocs /app
37+
38+
# Cambiar a usuario no-root
39+
USER mkdocs
40+
41+
# Exponer puerto
42+
EXPOSE 8000
43+
44+
# Health check
45+
HEALTHCHECK --interval=30s --timeout=30s --start-period=5s --retries=3 \
46+
CMD curl -f http://localhost:8000/ || exit 1
47+
48+
# Comando por defecto
49+
CMD ["mkdocs", "serve", "--dev-addr=0.0.0.0:8000"]
50+
51+
# Etiquetas de metadatos
52+
LABEL maintainer="Python CDMX <info@pythoncdmx.org>" \
53+
description="Sitio web oficial de Python CDMX Charlas" \
54+
version="1.0.0" \
55+
org.opencontainers.image.source="https://github.com/PythonMexico/python-cdmx-page"

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2024 Python CDMX
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

0 commit comments

Comments
 (0)