Merge pull request #54 from bitnami/phpbb_chart

Added phpBB Chart
This commit is contained in:
davidbhlm-github
2016-06-24 13:06:26 +02:00
committed by GitHub
6 changed files with 270 additions and 0 deletions

13
phpbb/Chart.yaml Normal file
View File

@@ -0,0 +1,13 @@
name: phpbb
home: https://www.phpbb.com/
source:
- https://github.com/bitnami/bitnami-docker-phpbb
version: 0.2.0
description: Community forum that supports the notion of users and groups, file attachments, full-text search, notifications and more.
maintainers:
- Bitnami <containers@bitnami.com>
dependencies:
- name: mariadb
version: 0.2.0
details: |-
phpBB is a community forum that supports the notion of users and groups, file attachments, full-text search, notifications and more.

78
phpbb/README.md Normal file
View File

@@ -0,0 +1,78 @@
# phpBB
> If you need to build a community forum, try phpBB. First released in 2000, phpBB is a bulletin board solution that allows you to create forums and subforums. phpBB supports the notion of users and groups, file attachments, full-text search, notifications and more. Hundreds of modifications are available including themes, communications add-ons, spam management and more.
Based on the [Bitnami phpBB](https://github.com/bitnami/bitnami-docker-phpbb) image for docker, this Chart bootstraps a [phpBB](https://www.phpbb.com/) deployment on a [Kubernetes](https://kubernetes.io) cluster using [Helm](https://helm.sh).
## Dependencies
The phpBB Chart requires the [Bitnami MariaDB Chart](https://github.com/bitnami/charts/tree/master/mariadb) for setting up a database backend.
Please refer to the [README](https://github.com/bitnami/charts/tree/master/mariadb) of the Bitnami MariaDB Chart for deployment instructions.
## Persistence
> *You may skip this section if your only interested in testing the phpBB Chart and have not yet made the decision to use it for your production workloads.*
For persistence of the phpBB configuration and user file uploads, mount a [storage volume](http://kubernetes.io/v1.0/docs/user-guide/volumes.html) at the `/bitnami/phpbb` path of the phpBB pod.
By default the phpBB Chart mounts an [emptyDir](http://kubernetes.io/docs/user-guide/volumes/#emptydir) volume.
## Configuration
To edit the default phpBB configuration, run
```bash
$ helmc edit phpbb
```
Here you can update the MariaDB root password, phpBB admin username, password and email address in `tpl/values.toml`. When not specified, the default values are used.
Refer to the [Environment variables](https://github.com/bitnami/bitnami-docker-phpbb/#environment-variables) section of the [Bitnami phpBB](https://github.com/bitnami/bitnami-docker-phpbb) image for the default values.
The values of `phpbbUser` and `phpbbPassword` are the login credentials when you [access the phpBB instance](#access-your-phpbb-application).
> Note:
>
> If you had updated the MariaDB root password for the MariaDB deployment, then ensure you set the same password for the `mariadbRootPassword` field in the phpBB Chart.
Finally, generate the chart to apply your changes to the configuration.
```bash
$ helmc generate --force php
```
## Access your phpBB application
You should now be able to access the application using the external IP configured for the phpBB service.
> Note:
>
> On GKE, the service will automatically configure a firewall rule so that the phpBB instance is accessible from the internet, for which you will be charged additionally.
>
> On other cloud platforms you may have to setup a firewall rule manually. Please refer your cloud providers documentation.
Get the external IP address of your phpBB instance using:
```bash
$ kubectl get services phpbb
NAME CLUSTER_IP EXTERNAL_IP PORT(S) SELECTOR AGE
phpbb 10.63.246.116 146.148.20.117 80/TCP,443/TCP app=phpbb 15m
```
Access your phpBB deployment using the IP address listed under the `EXTERNAL_IP` column.
The default credentials are:
- Username: `user`
- Password: `bitnami`
## Cleanup
To delete the phpBB deployment completely:
```bash
$ helmc uninstall -n default phpbb
```
Additionally you may want to [Cleanup the MariaDB Chart](https://github.com/bitnami/charts/tree/master/mariadb#cleanup)

View File

@@ -0,0 +1,70 @@
#helm:generate helmc tpl -d tpl/values.toml -o manifests/phpbb-rc.yaml $HELM_GENERATE_FILE
apiVersion: v1
kind: ReplicationController
metadata:
name: phpbb
labels:
app: phpbb
provider: phpbb-server
heritage: bitnami
spec:
replicas: 1
selector:
app: phpbb
provider: phpbb-server
version: 3.1.9-r0
template:
metadata:
labels:
app: phpbb
provider: phpbb-server
version: 3.1.9-r0
heritage: bitnami
spec:
containers:
- name: phpbb
image: bitnami/phpbb:3.1.9-r0
env:
- name: MARIADB_HOST
value: "mariadb"
- name: MARIADB_PORT
value: "3306"
- name: MARIADB_PASSWORD
value: ""
- name: PHPBB_USERNAME
value: "user"
- name: PHPBB_PASSWORD
value: "bitnami"
- name: PHPBB_EMAIL
value: "user@example.com"
ports:
- name: http
containerPort: 80
- name: https
containerPort: 443
livenessProbe:
httpGet:
path: /
port: http
initialDelaySeconds: 120
timeoutSeconds: 5
readinessProbe:
httpGet:
path: /
port: http
initialDelaySeconds: 5
timeoutSeconds: 1
volumeMounts:
- name: phpbb-data
mountPath: /bitnami/phpbb
- name: apache-data
mountPath: /bitnami/apache
- name: php-data
mountPath: /bitnami/php
volumes:
- name: phpbb-data
emptyDir: {}
- name: apache-data
emptyDir: {}
- name: php-data
emptyDir: {}

View File

@@ -0,0 +1,20 @@
apiVersion: v1
kind: Service
metadata:
name: phpbb
labels:
app: phpbb
provider: phpbb-server
heritage: bitnami
spec:
type: LoadBalancer
ports:
- name: http
port: 80
targetPort: http
- name: https
port: 443
targetPort: https
selector:
app: phpbb
provider: phpbb-server

80
phpbb/tpl/phpbb-rc.yaml Normal file
View File

@@ -0,0 +1,80 @@
#helm:generate helmc tpl -d tpl/values.toml -o manifests/phpbb-rc.yaml $HELM_GENERATE_FILE
apiVersion: v1
kind: ReplicationController
metadata:
name: phpbb
labels:
app: phpbb
provider: phpbb-server
heritage: bitnami
spec:
replicas: 1
selector:
app: phpbb
provider: phpbb-server
version: 3.1.9-r0
template:
metadata:
labels:
app: phpbb
provider: phpbb-server
version: 3.1.9-r0
heritage: bitnami
spec:
containers:
- name: phpbb
image: bitnami/phpbb:3.1.9-r0
env:
- name: MARIADB_HOST
value: "mariadb"
- name: MARIADB_PORT
value: "3306"
- name: MARIADB_PASSWORD
value: {{ .mariadbRootPassword | quote }}
- name: PHPBB_USERNAME
value: {{ .phpbbUser | quote }}
- name: PHPBB_PASSWORD
value: {{ .phpbbPassword | quote }}
- name: PHPBB_EMAIL
value: {{ .phpbbEmail | quote }}
- name: SMTP_HOST
value: {{ .smtpHost | quote }}
- name: SMTP_PORT
value: {{ .smtpPort | quote }}
- name: SMTP_USER
value: {{ .smtpUser | quote }}
- name: SMTP_PASSWORD
value: {{ .smtpPassword | quote }}
- name: SMTP_PROTOCOL
value: {{ .smtpProtocol | quote }}
ports:
- name: http
containerPort: 80
- name: https
containerPort: 443
livenessProbe:
httpGet:
path: /
port: http
initialDelaySeconds: 120
timeoutSeconds: 5
readinessProbe:
httpGet:
path: /
port: http
initialDelaySeconds: 5
timeoutSeconds: 1
volumeMounts:
- name: phpbb-data
mountPath: /bitnami/phpbb
- name: apache-data
mountPath: /bitnami/apache
- name: php-data
mountPath: /bitnami/php
volumes:
- name: phpbb-data
emptyDir: {}
- name: apache-data
emptyDir: {}
- name: php-data
emptyDir: {}

9
phpbb/tpl/values.toml Normal file
View File

@@ -0,0 +1,9 @@
mariadbRootPassword = ""
phpbbUser = "user"
phpbbPassword = "bitnami"
phpbbEmail = "user@example.com"
smtpHost = ""
smtpUser = ""
smtpPassword = ""
smtpPort = ""
smtpProtocol = ""