mirror of
https://github.com/invoiceninja/dockerfiles.git
synced 2026-01-31 19:27:09 +01:00
Compare commits
11 Commits
5.2.2
...
invoicenin
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
225c0eb275 | ||
|
|
34878d0f93 | ||
|
|
8b9e69d51b | ||
|
|
7238e521e6 | ||
|
|
5a1bf5c430 | ||
|
|
7a935a0eef | ||
|
|
ff897d568f | ||
|
|
b0bb0ffd25 | ||
|
|
3902b40bc1 | ||
|
|
29e2d93e59 | ||
|
|
b7aea66e62 |
2
.github/ct-install.yaml
vendored
2
.github/ct-install.yaml
vendored
@@ -3,4 +3,4 @@ chart-dirs:
|
|||||||
chart-repos:
|
chart-repos:
|
||||||
- bitnami=https://charts.bitnami.com/bitnami
|
- bitnami=https://charts.bitnami.com/bitnami
|
||||||
check-version-increment: true
|
check-version-increment: true
|
||||||
debug: true
|
debug: false
|
||||||
|
|||||||
57
.github/workflows/build-image-v5.yml
vendored
Normal file
57
.github/workflows/build-image-v5.yml
vendored
Normal file
@@ -0,0 +1,57 @@
|
|||||||
|
name: Build Container Image
|
||||||
|
|
||||||
|
# When its time to do a release do a full cross platform build for all supported
|
||||||
|
# architectures and push all of them to Docker Hub.
|
||||||
|
# Only trigger on semver shaped tags.
|
||||||
|
# Ref: https://github.com/metcalfc/docker-action-examples/blob/main/.github/workflows/release.yml
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
paths:
|
||||||
|
- "alpine/5/**"
|
||||||
|
push:
|
||||||
|
paths:
|
||||||
|
- "alpine/5/**"
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
docker:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Set up QEMU
|
||||||
|
uses: docker/setup-qemu-action@v1
|
||||||
|
with:
|
||||||
|
platforms: all
|
||||||
|
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
id: buildx
|
||||||
|
uses: docker/setup-buildx-action@v1
|
||||||
|
|
||||||
|
- name: Cache Docker layers
|
||||||
|
uses: actions/cache@v2
|
||||||
|
with:
|
||||||
|
path: /tmp/.buildx-cache
|
||||||
|
key: ${{ runner.os }}-buildx-5-${{ hashFiles('alpine/5/cache_buster') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-buildx-5-${{ hashFiles('alpine/5/cache_buster') }}
|
||||||
|
|
||||||
|
- name: Build
|
||||||
|
id: docker_build
|
||||||
|
uses: docker/build-push-action@v2
|
||||||
|
with:
|
||||||
|
builder: ${{ steps.buildx.outputs.name }}
|
||||||
|
context: ./alpine/5/
|
||||||
|
build-args: INVOICENINJA_VERSION=5-stable
|
||||||
|
target: prod
|
||||||
|
platforms: linux/amd64,linux/arm64
|
||||||
|
tags: invoiceninja/invoiceninja:cache
|
||||||
|
cache-from: type=local,src=/tmp/.buildx-cache
|
||||||
|
cache-to: type=local,dest=/tmp/.buildx-cache-new
|
||||||
|
|
||||||
|
- name: Move cache
|
||||||
|
run: |
|
||||||
|
rm -rf /tmp/.buildx-cache
|
||||||
|
mv /tmp/.buildx-cache-new /tmp/.buildx-cache
|
||||||
34
.github/workflows/charts.yaml
vendored
34
.github/workflows/charts.yaml
vendored
@@ -13,9 +13,8 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
- name: Fetch history
|
fetch-depth: 0
|
||||||
run: git fetch --prune --unshallow
|
|
||||||
|
|
||||||
- name: Set up Helm
|
- name: Set up Helm
|
||||||
uses: azure/setup-helm@v1
|
uses: azure/setup-helm@v1
|
||||||
@@ -41,6 +40,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Run chart-testing (lint)
|
- name: Run chart-testing (lint)
|
||||||
run: ct lint --config .github/ct-lint.yaml
|
run: ct lint --config .github/ct-lint.yaml
|
||||||
|
|
||||||
kubeval-chart:
|
kubeval-chart:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs:
|
needs:
|
||||||
@@ -49,9 +49,9 @@ jobs:
|
|||||||
matrix:
|
matrix:
|
||||||
chart: ${{ fromJson(needs.lint-chart.outputs.matrix) }}
|
chart: ${{ fromJson(needs.lint-chart.outputs.matrix) }}
|
||||||
k8s:
|
k8s:
|
||||||
- v1.17.11
|
- v1.19.11
|
||||||
- v1.18.8
|
- v1.20.7
|
||||||
- v1.19.4
|
- v1.21.2
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v1
|
uses: actions/checkout@v1
|
||||||
@@ -79,20 +79,26 @@ jobs:
|
|||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
k8s:
|
k8s:
|
||||||
- v1.17.11
|
- v1.19.11
|
||||||
- v1.18.8
|
- v1.20.7
|
||||||
- v1.19.4
|
- v1.21.2
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
- name: Create kind ${{ matrix.k8s }} cluster
|
- name: Create kind ${{ matrix.k8s }} cluster
|
||||||
uses: helm/kind-action@v1.1.0
|
uses: helm/kind-action@v1.2.0
|
||||||
with:
|
with:
|
||||||
node_image: kindest/node:${{ matrix.k8s }}
|
node_image: kindest/node:${{ matrix.k8s }}
|
||||||
|
|
||||||
- name: Run chart-testing (install)
|
- uses: actions/setup-python@v2
|
||||||
uses: helm/chart-testing-action@v2.0.1
|
|
||||||
with:
|
with:
|
||||||
command: install
|
python-version: 3.7
|
||||||
config: .github/ct-install.yaml
|
|
||||||
|
- name: Set up chart-testing
|
||||||
|
uses: helm/chart-testing-action@v2.0.1
|
||||||
|
|
||||||
|
- name: Run chart-testing (install)
|
||||||
|
run: ct install --config .github/ct-install.yaml
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
name: Publish Releases to Hub
|
name: Publish Container Image
|
||||||
|
|
||||||
# When its time to do a release do a full cross platform build for all supported
|
# When its time to do a release do a full cross platform build for all supported
|
||||||
# architectures and push all of them to Docker Hub.
|
# architectures and push all of them to Docker Hub.
|
||||||
@@ -44,13 +44,13 @@ jobs:
|
|||||||
id: buildx
|
id: buildx
|
||||||
uses: docker/setup-buildx-action@v1
|
uses: docker/setup-buildx-action@v1
|
||||||
|
|
||||||
# - name: Cache Docker layers
|
- name: Cache Docker layers
|
||||||
# uses: actions/cache@v2
|
uses: actions/cache@v2
|
||||||
# with:
|
with:
|
||||||
# path: /tmp/.buildx-cache
|
path: /tmp/.buildx-cache
|
||||||
# key: ${{ runner.os }}-buildx-${{ github.sha }}
|
key: ${{ runner.os }}-buildx-${{ steps.prep.outputs.major }}-${{ hashFiles('alpine/${{ steps.prep.outputs.major }}/cache_buster') }}
|
||||||
# restore-keys: |
|
restore-keys: |
|
||||||
# ${{ runner.os }}-buildx-
|
${{ runner.os }}-buildx-${{ steps.prep.outputs.major }}-${{ hashFiles('alpine/${{ steps.prep.outputs.major }}/cache_buster') }}
|
||||||
|
|
||||||
- name: Login to DockerHub
|
- name: Login to DockerHub
|
||||||
if: github.event_name != 'pull_request'
|
if: github.event_name != 'pull_request'
|
||||||
@@ -70,8 +70,13 @@ jobs:
|
|||||||
platforms: linux/amd64,linux/arm64
|
platforms: linux/amd64,linux/arm64
|
||||||
push: ${{ github.event_name != 'pull_request' }}
|
push: ${{ github.event_name != 'pull_request' }}
|
||||||
tags: ${{ steps.prep.outputs.tags }}
|
tags: ${{ steps.prep.outputs.tags }}
|
||||||
cache-from: invoiceninja/invoiceninja:${{ steps.prep.outputs.major }}
|
cache-from: type=local,src=/tmp/.buildx-cache
|
||||||
cache-to: type=inline
|
cache-to: type=local,dest=/tmp/.buildx-cache-new
|
||||||
|
|
||||||
|
- name: Move cache
|
||||||
|
run: |
|
||||||
|
rm -rf /tmp/.buildx-cache
|
||||||
|
mv /tmp/.buildx-cache-new /tmp/.buildx-cache
|
||||||
|
|
||||||
- name: Image digest
|
- name: Image digest
|
||||||
run: echo ${{ steps.docker_build.outputs.digest }}
|
run: echo ${{ steps.docker_build.outputs.digest }}
|
||||||
@@ -2,6 +2,8 @@
|
|||||||
[](https://hub.docker.com/r/invoiceninja/invoiceninja)
|
[](https://hub.docker.com/r/invoiceninja/invoiceninja)
|
||||||
[](https://hub.docker.com/r/invoiceninja/invoiceninja)
|
[](https://hub.docker.com/r/invoiceninja/invoiceninja)
|
||||||
[](https://artifacthub.io/packages/search?repo=invoiceninja)
|
[](https://artifacthub.io/packages/search?repo=invoiceninja)
|
||||||
|
[](https://github.com/invoiceninja/dockerfiles/actions/workflows/publish-image.yaml) [](https://github.com/invoiceninja/dockerfiles/actions/workflows/build-image-v5.yaml)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Docker for [Invoice Ninja](https://www.invoiceninja.com/)
|
# Docker for [Invoice Ninja](https://www.invoiceninja.com/)
|
||||||
|
|||||||
@@ -4,11 +4,9 @@ ARG BAK_PUBLIC_PATH=/var/www/app/docker-backup-public/
|
|||||||
|
|
||||||
# Get Invoice Ninja and install nodejs packages
|
# Get Invoice Ninja and install nodejs packages
|
||||||
FROM --platform=$BUILDPLATFORM node:lts-alpine as build
|
FROM --platform=$BUILDPLATFORM node:lts-alpine as build
|
||||||
ARG INVOICENINJA_VERSION
|
|
||||||
ARG BAK_STORAGE_PATH
|
|
||||||
ARG BAK_PUBLIC_PATH
|
|
||||||
|
|
||||||
# Download Invoice Ninja
|
# Download Invoice Ninja
|
||||||
|
ARG INVOICENINJA_VERSION
|
||||||
ADD https://github.com/invoiceninja/invoiceninja/tarball/v$INVOICENINJA_VERSION /tmp/ninja.tar.gz
|
ADD https://github.com/invoiceninja/invoiceninja/tarball/v$INVOICENINJA_VERSION /tmp/ninja.tar.gz
|
||||||
|
|
||||||
# Extract Invoice Ninja
|
# Extract Invoice Ninja
|
||||||
@@ -21,6 +19,8 @@ RUN mkdir -p /var/www/app \
|
|||||||
WORKDIR /var/www/app/
|
WORKDIR /var/www/app/
|
||||||
|
|
||||||
# Install node packages
|
# Install node packages
|
||||||
|
ARG BAK_STORAGE_PATH
|
||||||
|
ARG BAK_PUBLIC_PATH
|
||||||
RUN npm install --production \
|
RUN npm install --production \
|
||||||
&& npm run production \
|
&& npm run production \
|
||||||
&& rm -rf node_modules \
|
&& rm -rf node_modules \
|
||||||
@@ -28,10 +28,7 @@ RUN npm install --production \
|
|||||||
&& mv /var/www/app/public $BAK_PUBLIC_PATH
|
&& mv /var/www/app/public $BAK_PUBLIC_PATH
|
||||||
|
|
||||||
# Prepare php image
|
# Prepare php image
|
||||||
FROM php:${PHP_VERSION}-fpm-alpine as prod
|
FROM php:${PHP_VERSION}-fpm-alpine3.13 as prod
|
||||||
ARG INVOICENINJA_VERSION
|
|
||||||
ARG BAK_STORAGE_PATH
|
|
||||||
ARG BAK_PUBLIC_PATH
|
|
||||||
|
|
||||||
LABEL maintainer="David Bomba <turbo124@gmail.com>"
|
LABEL maintainer="David Bomba <turbo124@gmail.com>"
|
||||||
|
|
||||||
@@ -78,6 +75,9 @@ RUN addgroup --gid=$UID -S "$INVOICENINJA_USER" \
|
|||||||
"$INVOICENINJA_USER"
|
"$INVOICENINJA_USER"
|
||||||
|
|
||||||
# Set up app
|
# Set up app
|
||||||
|
ARG INVOICENINJA_VERSION
|
||||||
|
ARG BAK_STORAGE_PATH
|
||||||
|
ARG BAK_PUBLIC_PATH
|
||||||
ENV INVOICENINJA_VERSION $INVOICENINJA_VERSION
|
ENV INVOICENINJA_VERSION $INVOICENINJA_VERSION
|
||||||
ENV BAK_STORAGE_PATH $BAK_STORAGE_PATH
|
ENV BAK_STORAGE_PATH $BAK_STORAGE_PATH
|
||||||
ENV BAK_PUBLIC_PATH $BAK_PUBLIC_PATH
|
ENV BAK_PUBLIC_PATH $BAK_PUBLIC_PATH
|
||||||
@@ -88,8 +88,7 @@ WORKDIR /var/www/app
|
|||||||
|
|
||||||
# Do not remove this ENV
|
# Do not remove this ENV
|
||||||
ENV IS_DOCKER true
|
ENV IS_DOCKER true
|
||||||
RUN /usr/local/bin/composer install --no-dev --quiet \
|
RUN /usr/local/bin/composer install --no-dev --quiet
|
||||||
&& rm .env
|
|
||||||
|
|
||||||
# Override the environment settings from projects .env file
|
# Override the environment settings from projects .env file
|
||||||
ENV APP_ENV production
|
ENV APP_ENV production
|
||||||
|
|||||||
1
alpine/5/cache_buster
Normal file
1
alpine/5/cache_buster
Normal file
@@ -0,0 +1 @@
|
|||||||
|
Fri Jul 2 7:33:22 +00 2021
|
||||||
@@ -1,15 +1,15 @@
|
|||||||
dependencies:
|
dependencies:
|
||||||
- name: common
|
- name: common
|
||||||
repository: https://charts.bitnami.com/bitnami
|
repository: https://charts.bitnami.com/bitnami
|
||||||
version: 1.4.3
|
version: 1.7.0
|
||||||
- name: nginx
|
- name: nginx
|
||||||
repository: https://charts.bitnami.com/bitnami
|
repository: https://charts.bitnami.com/bitnami
|
||||||
version: 8.8.5
|
version: 9.3.6
|
||||||
- name: mariadb
|
- name: mariadb
|
||||||
repository: https://charts.bitnami.com/bitnami
|
repository: https://charts.bitnami.com/bitnami
|
||||||
version: 9.3.11
|
version: 9.3.16
|
||||||
- name: redis
|
- name: redis
|
||||||
repository: https://charts.bitnami.com/bitnami
|
repository: https://charts.bitnami.com/bitnami
|
||||||
version: 12.9.2
|
version: 14.6.6
|
||||||
digest: sha256:4255a558312b033e820635f491b0960bd4ec8e716164025212af06adafbd4cb9
|
digest: sha256:675a7e41183e23844b8c3c589e25c2fafccd394cd03710e0a2b35d72db436d70
|
||||||
generated: "2021-05-11T09:31:45.433+08:00"
|
generated: "2021-07-08T00:30:57.000141+08:00"
|
||||||
|
|||||||
@@ -13,11 +13,11 @@ type: application
|
|||||||
# This is the chart version. This version number should be incremented each time you make changes
|
# This is the chart version. This version number should be incremented each time you make changes
|
||||||
# to the chart and its templates, including the app version.
|
# to the chart and its templates, including the app version.
|
||||||
# Versions are expected to follow Semantic Versioning (https://semver.org/)
|
# Versions are expected to follow Semantic Versioning (https://semver.org/)
|
||||||
version: 0.5.1
|
version: 0.7.2
|
||||||
# This is the version number of the application being deployed. This version number should be
|
# This is the version number of the application being deployed. This version number should be
|
||||||
# incremented each time you make changes to the application. Versions are not expected to
|
# incremented each time you make changes to the application. Versions are not expected to
|
||||||
# follow Semantic Versioning. They should reflect the version the application is using.
|
# follow Semantic Versioning. They should reflect the version the application is using.
|
||||||
appVersion: 5.1.64
|
appVersion: 5.2.10
|
||||||
keywords:
|
keywords:
|
||||||
- invoiceninja
|
- invoiceninja
|
||||||
home: https://invoiceninja.github.io/dockerfiles
|
home: https://invoiceninja.github.io/dockerfiles
|
||||||
@@ -32,7 +32,7 @@ dependencies:
|
|||||||
version: 1.x.x
|
version: 1.x.x
|
||||||
- name: nginx
|
- name: nginx
|
||||||
repository: https://charts.bitnami.com/bitnami
|
repository: https://charts.bitnami.com/bitnami
|
||||||
version: 8.8.x
|
version: 9.x.x
|
||||||
- condition: mariadb.enabled
|
- condition: mariadb.enabled
|
||||||
name: mariadb
|
name: mariadb
|
||||||
repository: https://charts.bitnami.com/bitnami
|
repository: https://charts.bitnami.com/bitnami
|
||||||
@@ -40,7 +40,7 @@ dependencies:
|
|||||||
- condition: redis.enabled
|
- condition: redis.enabled
|
||||||
name: redis
|
name: redis
|
||||||
repository: https://charts.bitnami.com/bitnami
|
repository: https://charts.bitnami.com/bitnami
|
||||||
version: 12.9.x
|
version: 14.x.x
|
||||||
maintainers:
|
maintainers:
|
||||||
- email: lwj5@hotmail.com
|
- email: lwj5@hotmail.com
|
||||||
name: lwj5
|
name: lwj5
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ Please read [Upgrading](#upgrading) section before upgrading MAJOR versions.
|
|||||||
- The Bitnami [mariadb](https://github.com/bitnami/charts/tree/master/bitnami/mariadb) helm chart
|
- The Bitnami [mariadb](https://github.com/bitnami/charts/tree/master/bitnami/mariadb) helm chart
|
||||||
- The Bitnami [nginx](https://github.com/bitnami/charts/tree/master/bitnami/nginx) helm chart
|
- The Bitnami [nginx](https://github.com/bitnami/charts/tree/master/bitnami/nginx) helm chart
|
||||||
- The Bitnami [redis](https://github.com/bitnami/charts/tree/master/bitnami/redis) helm chart
|
- The Bitnami [redis](https://github.com/bitnami/charts/tree/master/bitnami/redis) helm chart
|
||||||
- Tested on Kubernetes 1.17+
|
- Tested on Kubernetes 1.19+
|
||||||
|
|
||||||
## Installing the Chart
|
## Installing the Chart
|
||||||
|
|
||||||
@@ -21,7 +21,7 @@ To install the chart with the release name `invoiceninja`:
|
|||||||
|
|
||||||
```bash
|
```bash
|
||||||
helm repo add invoiceninja https://invoiceninja.github.io/dockerfiles
|
helm repo add invoiceninja https://invoiceninja.github.io/dockerfiles
|
||||||
helm install invoiceninja invoiceninja/invoiceninja
|
helm install invoiceninja invoiceninja/invoiceninja --set appKey=changeit --set mariadb.auth.rootPassword=changeit --set mariadb.auth.password=changeit --set redis.password=changeit
|
||||||
```
|
```
|
||||||
|
|
||||||
The command deploys Invoice Ninja on the Kubernetes cluster in the default namespace. The [Parameters](#parameters) section lists the parameters that can be configured during installation.
|
The command deploys Invoice Ninja on the Kubernetes cluster in the default namespace. The [Parameters](#parameters) section lists the parameters that can be configured during installation.
|
||||||
@@ -70,31 +70,32 @@ The following table shows the configuration options for the Invoice Ninja helm c
|
|||||||
|
|
||||||
### Invoice Ninja parameters
|
### Invoice Ninja parameters
|
||||||
|
|
||||||
| Parameter | Description | Default |
|
| Parameter | Description | Default |
|
||||||
| -------------------- | ---------------------------------------------------------------- | ------------------------------------------------------- |
|
| -------------------- | ----------------------------------------------------------------------------- | ------------------------------------------------------- |
|
||||||
| `image.registry` | Invoice Ninja image registry | `docker.io` |
|
| `image.registry` | Invoice Ninja image registry | `docker.io` |
|
||||||
| `image.repository` | Invoice Ninja image name | `invoiceninja/invoiceninja` |
|
| `image.repository` | Invoice Ninja image name | `invoiceninja/invoiceninja` |
|
||||||
| `image.tag` | Invoice Ninja image tag | Check `values.yaml` file |
|
| `image.tag` | Invoice Ninja image tag | Check `values.yaml` file |
|
||||||
| `image.pullPolicy` | Invoice Ninja image pull policy | `IfNotPresent` |
|
| `image.pullPolicy` | Invoice Ninja image pull policy | `IfNotPresent` |
|
||||||
| `image.pullSecrets` | Specify docker-registry secret names as an array | `[]` (does not add image pull secrets to deployed pods) |
|
| `image.pullSecrets` | Specify docker-registry secret names as an array | `[]` (does not add image pull secrets to deployed pods) |
|
||||||
| `image.debug` | Specify if debug logs should be enabled | `false` |
|
| `image.debug` | Specify if debug logs should be enabled | `false` |
|
||||||
| `serviceAccountName` | Name of a service account for the Invoice Ninja pods | `default` |
|
| `serviceAccountName` | Name of a service account for the Invoice Ninja pods | `default` |
|
||||||
| `debug` | Turn on debug mode on Invoice Ninja | `false` |
|
| `debug` | Turn on debug mode on Invoice Ninja | `false` |
|
||||||
| `appKey` | Laravel Application Key | _random 32 character alphanumeric string_ |
|
| `appKey` | Laravel Application Key (ignored if existing secret is provided) | _random 32 character alphanumeric string_ |
|
||||||
| `userEmail` | Initial user email address | `admin@example.com` |
|
| `userEmail` | Initial user email address | `admin@example.com` |
|
||||||
| `userPassword` | Initial user password | `changeme!` |
|
| `userPassword` | Initial user password (ignored if existing secret is provided) | `changeme!` |
|
||||||
| `logChannel` | Name of log channel to use | `nil` |
|
| `logChannel` | Name of log channel to use | `nil` |
|
||||||
| `broadcastDriver` | Name of broadcast driver to use | `nil` |
|
| `broadcastDriver` | Name of broadcast driver to use | `nil` |
|
||||||
| `cacheDriver` | Name of cache driver to use | `nil` |
|
| `cacheDriver` | Name of cache driver to use | `nil` |
|
||||||
| `sessionDriver` | Name of session driver to use | `nil` |
|
| `sessionDriver` | Name of session driver to use | `nil` |
|
||||||
| `queueConnection` | Name of queue connection to use | `nil` |
|
| `queueConnection` | Name of queue connection to use | `nil` |
|
||||||
| `snappdf` | Use snappdf instead of Phantom JS PDF generation | `true` |
|
| `snappdf` | Use snappdf instead of Phantom JS PDF generation | `true` |
|
||||||
| `mailer` | Name of the mailer to use (log, smtp, etc.) | `log` |
|
| `mailer` | Name of the mailer to use (log, smtp, etc.) | `log` |
|
||||||
| `requireHttps` | Force HTTPS for internal connections to Invoice Ninja (see #349) | `false` |
|
| `requireHttps` | Force HTTPS for internal connections to Invoice Ninja (see #349) | `false` |
|
||||||
| `extraEnvVars` | Extra environment variables to be set on Invoice Ninja container | `{}` |
|
| `extraEnvVars` | Extra environment variables to be set on Invoice Ninja container | `{}` |
|
||||||
| `extraEnvVarsCM` | Name of existing ConfigMap containing extra env vars | `nil` |
|
| `extraEnvVarsCM` | Name of existing ConfigMap containing extra env vars | `nil` |
|
||||||
| `extraEnvVarsSecret` | Name of existing Secret containing extra env vars | `nil` |
|
| `extraEnvVarsSecret` | Name of existing Secret containing extra env vars | `nil` |
|
||||||
| `trustedProxy` | List of trusted proxies for Invoice Ninja to communicate with the nginx proxy | `'*'` |
|
| `trustedProxy` | List of trusted proxies for Invoice Ninja to communicate with the nginx proxy | `'*'` |
|
||||||
|
| `existingSecret` | Use existing secret that contain the keys `APP_KEY` and `IN_PASSWORD` | `nil` |
|
||||||
|
|
||||||
### Invoice Ninja deployment parameters
|
### Invoice Ninja deployment parameters
|
||||||
|
|
||||||
@@ -147,15 +148,13 @@ The following table shows the configuration options for the Invoice Ninja helm c
|
|||||||
|
|
||||||
### Ingress parameters
|
### Ingress parameters
|
||||||
|
|
||||||
| Parameter | Description | Default |
|
| Parameter | Description | Default |
|
||||||
| ------------------------------------------------------- | ------------------------------------- | ------------------------ |
|
| ------------------------------------ | ------------------------------------- | ------------------------------------------------------ |
|
||||||
| `nginx.service.type` | Kubernetes Service type | `ClusterIP` |
|
| `nginx.service.type` | Kubernetes Service type | `ClusterIP` |
|
||||||
| `nginx.ingress.enabled` | Enable ingress controller resource | `true` |
|
| `nginx.ingress.enabled` | Enable ingress controller resource | `true` |
|
||||||
| `nginx.ingress.hostname` | Default host for the ingress resource | `invoiceninja.local` |
|
| `nginx.ingress.hostname` | Default host for the ingress resource | `invoiceninja.local` |
|
||||||
| `nginx.serverBlock` | Custom NGINX server block | `nil` |
|
| `nginx.existingServerBlockConfigmap` | Custom NGINX server block config map | `{{ include "invoiceninja.nginx.serverBlockName" . }}` |
|
||||||
| `nginx.extraVolumes` | Array to add extra volumes | Check `values.yaml` file |
|
| `nginx.staticSitePVC` | Name of Invoice Ninja public PVC | `{{ include "invoiceninja.public.storageName" . }}` |
|
||||||
| `nginx.extraVolumes[0].persistentVolumeClaim.claimName` | Name of Invoice Ninja public PVC | `invoiceninja-public` |
|
|
||||||
| `nginx.extraVolumeMounts` | Array to add extra mount | Check `values.yaml` file |
|
|
||||||
|
|
||||||
> See [Dependencies](#dependencies) for more.
|
> See [Dependencies](#dependencies) for more.
|
||||||
|
|
||||||
@@ -181,9 +180,9 @@ The following table shows the configuration options for the Invoice Ninja helm c
|
|||||||
| Parameter | Description | Default |
|
| Parameter | Description | Default |
|
||||||
| --------------------------------- | -------------------------------------------- | ----------------------------------------- |
|
| --------------------------------- | -------------------------------------------- | ----------------------------------------- |
|
||||||
| `redis.enabled` | If external redis is used, set it to `false` | `true` |
|
| `redis.enabled` | If external redis is used, set it to `false` | `true` |
|
||||||
| `redis.password` | Redis password | _random 10 character alphanumeric string_ |
|
| `redis.auth.password` | Redis password | _random 10 character alphanumeric string_ |
|
||||||
|
| `redis.auth.sentinel` | Use password for sentinel containers | `false` |
|
||||||
| `redis.sentinel.enabled` | Enable sentinel containers | `true` |
|
| `redis.sentinel.enabled` | Enable sentinel containers | `true` |
|
||||||
| `redis.sentinel.usePassword` | Use password for sentinel containers | `false` |
|
|
||||||
| `externalRedis.host` | Host of the external redis | `nil` |
|
| `externalRedis.host` | Host of the external redis | `nil` |
|
||||||
| `externalRedis.port` | Port of the external redis | `6379` |
|
| `externalRedis.port` | Port of the external redis | `6379` |
|
||||||
| `externalRedis.password` | Password for the external redis | `nil` |
|
| `externalRedis.password` | Password for the external redis | `nil` |
|
||||||
@@ -286,4 +285,7 @@ extraEnvVarsCM: examplemap
|
|||||||
|
|
||||||
## Upgrading
|
## Upgrading
|
||||||
|
|
||||||
Nothing yet.
|
### To 0.7.0
|
||||||
|
|
||||||
|
Redis chart dependency has been upgraded and may not be backwards compatible with previous versions. See [here](https://github.com/bitnami/charts/tree/master/bitnami/redis) for more info.
|
||||||
|
|
||||||
|
|||||||
@@ -55,6 +55,13 @@ Create the name of the service account to use
|
|||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Return the Invoice Ninja Secret Name
|
||||||
|
*/}}
|
||||||
|
{{- define "invoiceninja.secretName" -}}
|
||||||
|
{{- default (include "common.names.fullname" .) .Values.existingSecret }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
{{/*
|
{{/*
|
||||||
Return the proper Storage Class
|
Return the proper Storage Class
|
||||||
*/}}
|
*/}}
|
||||||
@@ -138,7 +145,11 @@ Return the MariaDB Secret Name
|
|||||||
{{- if .Values.externalDatabase.existingSecret -}}
|
{{- if .Values.externalDatabase.existingSecret -}}
|
||||||
{{- printf "%s" .Values.externalDatabase.existingSecret -}}
|
{{- printf "%s" .Values.externalDatabase.existingSecret -}}
|
||||||
{{- else -}}
|
{{- else -}}
|
||||||
{{- printf "%s" (include "invoiceninja.mariadb.fullname" .) -}}
|
{{- if .Values.mariadb.auth.existingSecret -}}
|
||||||
|
{{- printf "%s" .Values.mariadb.auth.existingSecret -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s" (include "invoiceninja.mariadb.fullname" .) -}}
|
||||||
|
{{- end -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
@@ -201,7 +212,11 @@ Return the Redis Secret Name
|
|||||||
{{- if .Values.externalRedis.existingSecret -}}
|
{{- if .Values.externalRedis.existingSecret -}}
|
||||||
{{- printf "%s" .Values.externalRedis.existingSecret -}}
|
{{- printf "%s" .Values.externalRedis.existingSecret -}}
|
||||||
{{- else -}}
|
{{- else -}}
|
||||||
{{- printf "%s" (include "invoiceninja.redis.fullname" .) -}}
|
{{- if .Values.redis.auth.existingSecret -}}
|
||||||
|
{{- printf "%s" .Values.redis.auth.existingSecret -}}
|
||||||
|
{{- else -}}
|
||||||
|
{{- printf "%s" (include "invoiceninja.redis.fullname" .) -}}
|
||||||
|
{{- end -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
@@ -248,3 +263,11 @@ Return the Session Connection Name
|
|||||||
{{- printf "default" -}}
|
{{- printf "default" -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Server block configmap name for nignx.
|
||||||
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||||
|
*/}}
|
||||||
|
{{- define "invoiceninja.nginx.serverBlockName" -}}
|
||||||
|
{{- printf "%s-%s" .Release.Name "server-block" | trunc 63 | trimSuffix "-" -}}
|
||||||
|
{{- end -}}
|
||||||
|
|||||||
@@ -135,8 +135,10 @@ spec:
|
|||||||
timeoutSeconds: {{ $.Values.livenessProbe.timeoutSeconds }}
|
timeoutSeconds: {{ $.Values.livenessProbe.timeoutSeconds }}
|
||||||
successThreshold: {{ $.Values.livenessProbe.successThreshold }}
|
successThreshold: {{ $.Values.livenessProbe.successThreshold }}
|
||||||
failureThreshold: {{ $.Values.livenessProbe.failureThreshold }}
|
failureThreshold: {{ $.Values.livenessProbe.failureThreshold }}
|
||||||
tcpSocket:
|
exec:
|
||||||
port: {{ .Values.livenessProbe.port }}
|
command:
|
||||||
|
- pgrep
|
||||||
|
- php-fpm
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- if .Values.readinessProbe.enabled }}
|
{{- if .Values.readinessProbe.enabled }}
|
||||||
readinessProbe:
|
readinessProbe:
|
||||||
@@ -152,7 +154,7 @@ spec:
|
|||||||
- configMapRef:
|
- configMapRef:
|
||||||
name: {{ include "common.names.fullname" . }}
|
name: {{ include "common.names.fullname" . }}
|
||||||
- secretRef:
|
- secretRef:
|
||||||
name: {{ include "common.names.fullname" . }}
|
name: {{ include "invoiceninja.secretName" . }}
|
||||||
{{- if .Values.extraEnvVarsCM }}
|
{{- if .Values.extraEnvVarsCM }}
|
||||||
- configMapRef:
|
- configMapRef:
|
||||||
name: {{ include "common.tplvalues.render" (dict "value" .Values.extraEnvVarsCM "context" $) }}
|
name: {{ include "common.tplvalues.render" (dict "value" .Values.extraEnvVarsCM "context" $) }}
|
||||||
@@ -167,7 +169,7 @@ spec:
|
|||||||
secretKeyRef:
|
secretKeyRef:
|
||||||
name: {{ include "invoiceninja.databaseSecretName" . }}
|
name: {{ include "invoiceninja.databaseSecretName" . }}
|
||||||
key: mariadb-password
|
key: mariadb-password
|
||||||
{{- if or (and .Values.redis.enabled .Values.redis.usePassword) (or .Values.externalRedis.password .Values.externalRedis.existingSecret) }}
|
{{- if or (and .Values.redis.enabled .Values.redis.auth.enabled) (or .Values.externalRedis.password .Values.externalRedis.existingSecret) }}
|
||||||
- name: REDIS_PASSWORD
|
- name: REDIS_PASSWORD
|
||||||
valueFrom:
|
valueFrom:
|
||||||
secretKeyRef:
|
secretKeyRef:
|
||||||
|
|||||||
@@ -38,6 +38,7 @@ data:
|
|||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
||||||
---
|
---
|
||||||
|
{{- if not .Values.existingSecret }}
|
||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: Secret
|
kind: Secret
|
||||||
metadata:
|
metadata:
|
||||||
@@ -61,3 +62,4 @@ data:
|
|||||||
{{- if .Values.userPassword }}
|
{{- if .Values.userPassword }}
|
||||||
IN_PASSWORD: {{ .Values.userPassword | b64enc | quote }}
|
IN_PASSWORD: {{ .Values.userPassword | b64enc | quote }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
|
|||||||
39
charts/invoiceninja/templates/serverblock.yaml
Normal file
39
charts/invoiceninja/templates/serverblock.yaml
Normal file
@@ -0,0 +1,39 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
metadata:
|
||||||
|
name: {{ include "invoiceninja.nginx.serverBlockName" . }}
|
||||||
|
labels:
|
||||||
|
{{- include "common.labels.standard" $ | nindent 4 }}
|
||||||
|
{{- if .Values.commonLabels }}
|
||||||
|
{{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||||
|
{{- end }}
|
||||||
|
{{- if .Values.commonAnnotations }}
|
||||||
|
annotations:
|
||||||
|
{{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
|
||||||
|
{{- end }}
|
||||||
|
data:
|
||||||
|
server-block.conf: |-
|
||||||
|
server {
|
||||||
|
listen 8080 default_server;
|
||||||
|
server_name _;
|
||||||
|
|
||||||
|
root /app;
|
||||||
|
index index.php;
|
||||||
|
|
||||||
|
location / {
|
||||||
|
try_files $uri $uri/ /index.php?$query_string;
|
||||||
|
}
|
||||||
|
|
||||||
|
location = /favicon.ico { access_log off; log_not_found off; }
|
||||||
|
location = /robots.txt { access_log off; log_not_found off; }
|
||||||
|
|
||||||
|
location ~ \.php$ {
|
||||||
|
fastcgi_split_path_info ^(.+\.php)(/.+)$;
|
||||||
|
fastcgi_pass {{ include "common.names.fullname" . }}:9000;
|
||||||
|
fastcgi_index index.php;
|
||||||
|
include fastcgi_params;
|
||||||
|
fastcgi_param SCRIPT_FILENAME /var/www/app/public$fastcgi_script_name;
|
||||||
|
fastcgi_buffer_size 16k;
|
||||||
|
fastcgi_buffers 4 16k;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -18,7 +18,7 @@
|
|||||||
image:
|
image:
|
||||||
registry: docker.io
|
registry: docker.io
|
||||||
repository: invoiceninja/invoiceninja
|
repository: invoiceninja/invoiceninja
|
||||||
tag: 5.1.64
|
tag: 5.2.10
|
||||||
## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent'
|
## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent'
|
||||||
## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images
|
## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images
|
||||||
##
|
##
|
||||||
@@ -86,6 +86,12 @@ mailer: log
|
|||||||
##
|
##
|
||||||
requireHttps: false
|
requireHttps: false
|
||||||
|
|
||||||
|
## Name of existing secret containing IN credentials
|
||||||
|
## NOTE: Must contain key `APP_KEY` and `IN_PASSWORD`
|
||||||
|
## NOTE: When it's set, the `appKey` and `userPassword` parameter is ignored
|
||||||
|
##
|
||||||
|
existingSecret:
|
||||||
|
|
||||||
## String to partially override fullname template (will maintain the release name)
|
## String to partially override fullname template (will maintain the release name)
|
||||||
##
|
##
|
||||||
# nameOverride:
|
# nameOverride:
|
||||||
@@ -294,12 +300,11 @@ service:
|
|||||||
##
|
##
|
||||||
livenessProbe:
|
livenessProbe:
|
||||||
enabled: true
|
enabled: true
|
||||||
initialDelaySeconds: 30
|
initialDelaySeconds: 120
|
||||||
periodSeconds: 10
|
periodSeconds: 10
|
||||||
timeoutSeconds: 5
|
timeoutSeconds: 5
|
||||||
failureThreshold: 6
|
failureThreshold: 6
|
||||||
successThreshold: 1
|
successThreshold: 1
|
||||||
port: fastcgi
|
|
||||||
readinessProbe:
|
readinessProbe:
|
||||||
enabled: true
|
enabled: true
|
||||||
initialDelaySeconds: 15
|
initialDelaySeconds: 15
|
||||||
@@ -377,9 +382,10 @@ autoscaling:
|
|||||||
##
|
##
|
||||||
redis:
|
redis:
|
||||||
enabled: true
|
enabled: true
|
||||||
|
auth:
|
||||||
|
sentinel: false
|
||||||
sentinel:
|
sentinel:
|
||||||
enabled: true
|
enabled: true
|
||||||
usePassword: false
|
|
||||||
|
|
||||||
## External Redis Configuration
|
## External Redis Configuration
|
||||||
##
|
##
|
||||||
@@ -469,43 +475,9 @@ nginx:
|
|||||||
ingress:
|
ingress:
|
||||||
enabled: true
|
enabled: true
|
||||||
hostname: invoiceninja.local
|
hostname: invoiceninja.local
|
||||||
## Configure the serverblock for Invoice Ninja
|
## Use the serverblock config map from Invoice Ninja
|
||||||
## Note: you may need to replace the fastcgi_pass value if the release name is different
|
|
||||||
##
|
##
|
||||||
serverBlock: |
|
existingServerBlockConfigmap: '{{ include "invoiceninja.nginx.serverBlockName" . }}'
|
||||||
server {
|
## Use the public PVC created by Invoice Ninja
|
||||||
listen 8080 default_server;
|
|
||||||
server_name _;
|
|
||||||
|
|
||||||
root /var/www/app/public/;
|
|
||||||
index index.php;
|
|
||||||
|
|
||||||
location / {
|
|
||||||
try_files $uri $uri/ /index.php?$query_string;
|
|
||||||
}
|
|
||||||
|
|
||||||
location = /favicon.ico { access_log off; log_not_found off; }
|
|
||||||
location = /robots.txt { access_log off; log_not_found off; }
|
|
||||||
|
|
||||||
location ~ \.php$ {
|
|
||||||
fastcgi_split_path_info ^(.+\.php)(/.+)$;
|
|
||||||
fastcgi_pass invoiceninja:9000;
|
|
||||||
fastcgi_index index.php;
|
|
||||||
include fastcgi_params;
|
|
||||||
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
|
|
||||||
fastcgi_intercept_errors off;
|
|
||||||
fastcgi_buffer_size 16k;
|
|
||||||
fastcgi_buffers 4 16k;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
## Configure the extraVolumes and extraVolumeMounts for Invoice Ninja
|
|
||||||
## Note: you may need to replace the claimName if the release name is different
|
|
||||||
##
|
##
|
||||||
extraVolumes:
|
staticSitePVC: '{{ include "invoiceninja.public.storageName" . }}'
|
||||||
- name: public
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: invoiceninja-public
|
|
||||||
extraVolumeMounts:
|
|
||||||
- mountPath: /var/www/app/public
|
|
||||||
name: public
|
|
||||||
readOnly: true
|
|
||||||
|
|||||||
Reference in New Issue
Block a user