Loading .gitignore +0 −1 Original line number Diff line number Diff line Loading @@ -32,5 +32,4 @@ build/ _build/ dist/ .tox/ roles db/ .gitlab-ci.yml 0 → 100644 +12 −0 Original line number Diff line number Diff line --- include: - project: shore/ci-templates file: templates/docker-compose.yml build: extends: .compose-build tags: [kodi.shore.co.il] run: extends: .compose-run tags: [kodi.shore.co.il] .pre-commit-config.yaml +34 −7 Original line number Diff line number Diff line # vim:ff=unix ts=2 sw=2 ai expandtab --- repos: - repo: https://github.com/pre-commit/pre-commit-hooks rev: v2.3.0 - repo: https://github.com/pre-commit/pre-commit-hooks.git rev: v3.4.0 hooks: - id: check-xml - id: check-added-large-files - id: check-executables-have-shebangs - id: check-merge-conflict - id: check-symlinks - id: check-toml files: Pipfile - id: check-xml - id: trailing-whitespace - repo: https://github.com/Yelp/detect-secrets rev: v0.14.3 hooks: - id: detect-secrets exclude: Pipfile\.lock - repo: https://github.com/adrienverge/yamllint rev: v1.17.0 rev: v1.25.0 hooks: - id: yamllint - repo: https://github.com/amperser/proselint/ rev: 0.10.1 rev: 0.10.2 hooks: - id: proselint types: [plain-text] exclude: LICENSE - repo: https://www.shore.co.il/git/docker-pre-commit - repo: https://github.com/executablebooks/mdformat.git rev: 0.5.3 hooks: - id: mdformat - repo: https://git.shore.co.il/nimrod/shell-pre-commit.git rev: v0.6.0 hooks: - id: shell-lint - repo: https://github.com/shellcheck-py/shellcheck-py.git rev: v0.7.1.1 hooks: - id: shellcheck - repo: https://git.shore.co.il/nimrod/docker-pre-commit.git/ rev: v0.3.0 hooks: - id: hadolint Loading Dockerfile +4 −4 Original line number Diff line number Diff line # hadolint ignore=DL3006 FROM adarnimrod/cron as supersonic FROM python:3.7-alpine FROM python:3.6-alpine3.12 COPY --from=supersonic /usr/local/bin/supersonic /usr/local/bin/ # hadolint ignore=DL3013 RUN pip install --no-cache-dir pipenv Loading @@ -12,9 +12,9 @@ RUN apk add --update --no-cache --virtual .lxml-build build-base libxslt-dev && pipenv install --deploy --system && \ apk del .lxml-build && \ apk add --update --no-cache --virtual .lxml-runtime libxml2 libxslt COPY --chown=root:root crontab /poquita/ COPY --chown=root:root poca.xml /poquita/ VOLUME /poquita/db/ /poquita/Podcasts/ COPY --chown=root:root crontab ./ COPY --chown=root:root poca.xml ./ VOLUME db Podcasts CMD [ "supersonic", "crontab" ] USER nobody HEALTHCHECK CMD pgrep supersonic Pipfile +3 −2 Original line number Diff line number Diff line Loading @@ -11,9 +11,10 @@ docker-compose = "*" poca = "*" [requires] python_version = "3.7" python_version = "3.6" [scripts] deploy = "docker-compose up --detach --build --remove-orphans" build = "docker-compose build --pull" deploy = "docker-compose up --detach --remove-orphans" subscribe = "poca-subscribe -c ." lint = "pre-commit" Loading
.gitignore +0 −1 Original line number Diff line number Diff line Loading @@ -32,5 +32,4 @@ build/ _build/ dist/ .tox/ roles db/
.gitlab-ci.yml 0 → 100644 +12 −0 Original line number Diff line number Diff line --- include: - project: shore/ci-templates file: templates/docker-compose.yml build: extends: .compose-build tags: [kodi.shore.co.il] run: extends: .compose-run tags: [kodi.shore.co.il]
.pre-commit-config.yaml +34 −7 Original line number Diff line number Diff line # vim:ff=unix ts=2 sw=2 ai expandtab --- repos: - repo: https://github.com/pre-commit/pre-commit-hooks rev: v2.3.0 - repo: https://github.com/pre-commit/pre-commit-hooks.git rev: v3.4.0 hooks: - id: check-xml - id: check-added-large-files - id: check-executables-have-shebangs - id: check-merge-conflict - id: check-symlinks - id: check-toml files: Pipfile - id: check-xml - id: trailing-whitespace - repo: https://github.com/Yelp/detect-secrets rev: v0.14.3 hooks: - id: detect-secrets exclude: Pipfile\.lock - repo: https://github.com/adrienverge/yamllint rev: v1.17.0 rev: v1.25.0 hooks: - id: yamllint - repo: https://github.com/amperser/proselint/ rev: 0.10.1 rev: 0.10.2 hooks: - id: proselint types: [plain-text] exclude: LICENSE - repo: https://www.shore.co.il/git/docker-pre-commit - repo: https://github.com/executablebooks/mdformat.git rev: 0.5.3 hooks: - id: mdformat - repo: https://git.shore.co.il/nimrod/shell-pre-commit.git rev: v0.6.0 hooks: - id: shell-lint - repo: https://github.com/shellcheck-py/shellcheck-py.git rev: v0.7.1.1 hooks: - id: shellcheck - repo: https://git.shore.co.il/nimrod/docker-pre-commit.git/ rev: v0.3.0 hooks: - id: hadolint Loading
Dockerfile +4 −4 Original line number Diff line number Diff line # hadolint ignore=DL3006 FROM adarnimrod/cron as supersonic FROM python:3.7-alpine FROM python:3.6-alpine3.12 COPY --from=supersonic /usr/local/bin/supersonic /usr/local/bin/ # hadolint ignore=DL3013 RUN pip install --no-cache-dir pipenv Loading @@ -12,9 +12,9 @@ RUN apk add --update --no-cache --virtual .lxml-build build-base libxslt-dev && pipenv install --deploy --system && \ apk del .lxml-build && \ apk add --update --no-cache --virtual .lxml-runtime libxml2 libxslt COPY --chown=root:root crontab /poquita/ COPY --chown=root:root poca.xml /poquita/ VOLUME /poquita/db/ /poquita/Podcasts/ COPY --chown=root:root crontab ./ COPY --chown=root:root poca.xml ./ VOLUME db Podcasts CMD [ "supersonic", "crontab" ] USER nobody HEALTHCHECK CMD pgrep supersonic
Pipfile +3 −2 Original line number Diff line number Diff line Loading @@ -11,9 +11,10 @@ docker-compose = "*" poca = "*" [requires] python_version = "3.7" python_version = "3.6" [scripts] deploy = "docker-compose up --detach --build --remove-orphans" build = "docker-compose build --pull" deploy = "docker-compose up --detach --remove-orphans" subscribe = "poca-subscribe -c ." lint = "pre-commit"