UNCLASSIFIED - NO CUI

Skip to content
Snippets Groups Projects
Commit b1d787d8 authored by Micah Nagel's avatar Micah Nagel
Browse files

Point to Minio BB Upstream

parent 4bd482c7
No related branches found
No related tags found
1 merge request!23Point to Minio BB Upstream
Showing
with 234 additions and 18 deletions
......@@ -4,6 +4,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
---
## [0.1.3-bb.2] - 2021-04-19
### Changed
- Pulled in official BB Minio via kpt
- Refactored the Minio connection secret
## [0.1.3-bb.1] - 2021-04-15
### Added
- Added Minio security context
......
......@@ -4,6 +4,6 @@ dependencies:
version: 10.3.5
- name: minio-instance
repository: file://./deps/minio
version: 2.0.9-bb.5
digest: sha256:e14a571d09ffdc66826b46a727ead36511ea5a6b0e349cda36d217bafcd26210
generated: "2021-03-22T15:12:25.740669-06:00"
version: 2.0.9-bb.9
digest: sha256:655a9483cf53a24afb867a32f3bcdaedced200bb5cdefb93b5889f79486e8b55
generated: "2021-04-19T09:54:43.894362-06:00"
......@@ -2,7 +2,7 @@
apiVersion: v2
name: mattermost
type: application
version: "0.1.3-bb.1"
version: "0.1.3-bb.2"
appVersion: "5.32.1"
description: "Deployment of mattermost"
keywords:
......@@ -17,7 +17,7 @@ dependencies:
condition: postgresql.install
repository: file://./deps/postgresql
- name: minio-instance
version: 2.0.9-bb.5
version: 2.0.9-bb.9
alias: minio
condition: minio.install
repository: file://./deps/minio
File deleted
File added
No preview for this file type
......@@ -9,7 +9,7 @@ description: |-
type: application
version: 2.0.9-bb.5
version: 2.0.9-bb.9
appVersion: RELEASE.2020-11-19T23-48-16Z
......
......@@ -5,7 +5,7 @@ metadata:
upstream:
type: git
git:
commit: 99d751b096154d9c5820af4a84ff4a0f99f4f7b7
commit: a8ef3702468317396a58ed94bb1823f9d4ae59cf
repo: https://repo1.dso.mil/platform-one/big-bang/apps/application-utilities/minio
directory: /chart
ref: 2.0.9-bb.5
ref: 2.0.9-bb.9
{
"pluginsFile": false,
"supportFile": false,
"fixturesFolder": false
}
describe('Basic Minio', function() {
it('Check Minio UI is accessible', function() {
cy.visit(Cypress.env('url'))
})
})
describe('Minio Login', function() {
it('Check Minio Login', function() {
cy.visit(Cypress.env('url')+"/minio/login")
// Fill the username
cy.get('[name="username"]')
.type(Cypress.env('accesskey'))
.should('have.value', Cypress.env('accesskey'));
// Fill the password
cy.get('[name="password"]')
.type(Cypress.env('secretkey'))
.should('have.value', Cypress.env('secretkey'));
// Locate and submit the form
cy.get('form').submit();
// Verify the app redirected you to the homepage
cy.location('pathname', { timeout: 10000 }).should('eq', '/minio/');
// Verify the page title is "Home"
cy.title().should('eq', 'MinIO Browser');
})
})
apiVersion: v1
kind: Secret
metadata:
name: minio-creds-secret
name: default-minio-creds-secret
namespace: {{ .Release.Namespace }}
type: Opaque
data:
accesskey: {{ .Values.accessKey | b64enc }}
secretkey: {{ .Values.secretKey | b64enc }}
accesskey: bWluaW8= # base 64 encoded "minio" (echo -n 'minio' | base64)
secretkey: bWluaW8xMjM= # based 64 encoded "minio123" (echo -n 'minio123' | base64)
---
......@@ -4,11 +4,25 @@ kind: VirtualService
metadata:
name: {{ template "minio.fullname" . }}
namespace: {{ .Release.Namespace }}
labels:
app: {{ template "minio.fullname" . }}
{{- include "minio.labels" . | nindent 4 }}
{{- if .Values.istio.virtualService.labels }}
{{ toYaml .Values.istio.virtualservice.labels | indent 4 }}
{{- end }}
{{- if .Values.istio.virtualService.annotations }}
annotations:
{{ toYaml .Values.istio.virtualService.annotations | indent 2 }}
{{- end }}
spec:
gateways:
- istio-system/main
{{- range .Values.istio.virtualService.gateways }}
- {{ . }}
{{- end }}
hosts:
- {{ .Values.istio.virtualService.name }}.{{ .Values.hostname }}
{{- range .Values.istio.virtualService.hosts }}
- {{ tpl . $}}
{{- end }}
http:
- match:
- uri:
......@@ -32,4 +46,3 @@ spec:
port:
number: {{ .Values.service.port }}
{{- end }}
......@@ -19,6 +19,14 @@ spec:
prometheus.io/scrape: "true"
{{- toYaml . | nindent 6 }}
{{- end }}
{{- if .Values.affinity }}
affinity:
{{ toYaml .Values.affinity | indent 8 }}
{{- end }}
{{- if .Values.nodeSelector }}
nodeSelector:
{{ toYaml .Values.nodeSelector | indent 8 }}
{{- end }}
## Registry location and Tag to download MinIO Server image
image: {{ .Values.image.name }}:{{ .Values.image.tag }}
......
apiVersion: v1
kind: ConfigMap
metadata:
name: "{{ .Release.Name }}-cypress-test-configmap"
annotations:
"helm.sh/hook": test-success
"helm.sh/hook-weight": "5"
sidecar.istio.io/inject: "false"
labels:
helm-test: enabled
{{- include "minio.labels" . | nindent 4 }}
namespace: {{ .Release.Namespace }}
data:
{{ (.Files.Glob "cypress/*").AsConfig | indent 2 }}
kind: Pod
apiVersion: v1
metadata:
name: "{{ .Release.Name }}-ui-test"
namespace: {{ .Release.Namespace }}
annotations:
"helm.sh/hook": test-success
"helm.sh/hook-weight": "20"
sidecar.istio.io/inject: "false"
labels:
helm-test: enabled
{{- include "minio.labels" . | nindent 4 }}
spec:
initContainers:
- name: copier
image: registry.dso.mil/platform-one/big-bang/pipeline-templates/pipeline-templates/cypress/included:5.0.0
command:
- "/bin/bash"
- "-c"
- |
ls -la /src/
cp /src/cypress.json /dest/
mkdir -p /dest/cypress/integration/
cp /src/*.js /dest/cypress/integration/
ls -la /dest/
ls -la /dest/cypress/integration/
volumeMounts:
- name: cypress-tests
mountPath: /src
- name: workdir
mountPath: /dest
containers:
- name: {{ .Release.Name }}-ui-test
image: registry.dso.mil/platform-one/big-bang/pipeline-templates/pipeline-templates/cypress/included:5.0.0
imagePullPolicy: {{ .Values.image.imagePullPolicy | quote }}
workingDir: /e2e
env:
- name: HOST
value: {{ .Values.service.port | quote }}
- name: MINIO_HOST
value: {{ include "minio.serviceName" . }}
- name: cypress_secretkey
valueFrom:
secretKeyRef:
name: {{ .Values.minioRootCreds }}
key: secretkey
- name: cypress_accesskey
valueFrom:
secretKeyRef:
name: {{ .Values.minioRootCreds }}
key: accesskey
- name: cypress_url
value: "http://{{ include "minio.serviceName" . }}:{{ .Values.service.port }}"
args:
- "--"
- "--reporter-options=list"
- "--reporter=spec"
volumeMounts:
- name: workdir
mountPath: /e2e/
restartPolicy: Never
volumes:
- name: cypress-tests
configMap:
name: "{{ .Release.Name }}-cypress-test-configmap"
- name: workdir
emptyDir: {}
kind: Pod
apiVersion: v1
metadata:
name: "{{ .Release.Name }}-access-test"
namespace: {{ .Release.Namespace }}
annotations:
"helm.sh/hook": test-success
"helm.sh/hook-weight": "10"
sidecar.istio.io/inject: "false"
labels:
helm-test: enabled
{{- include "minio.labels" . | nindent 4 }}
spec:
containers:
- name: {{ .Release.Name }}-credentials-test
image: {{.Values.mcImage }}
imagePullPolicy: {{ .Values.image.imagePullPolicy | quote }}
env:
- name: MINIO_PORT
value: {{ .Values.service.port | quote }}
- name: MINIO_HOST
value: {{ include "minio.serviceName" . }}
- name: SECRET_KEY
valueFrom:
secretKeyRef:
name: {{ .Values.minioRootCreds }}
key: secretkey
- name: ACCESS_KEY
valueFrom:
secretKeyRef:
name: {{ .Values.minioRootCreds }}
key: accesskey
command:
- /bin/bash
- -ec
- |-
set -x
mc config host add bigbang http://${MINIO_HOST}:${MINIO_PORT} ${ACCESS_KEY} ${SECRET_KEY}
# cleanup from pervious runs
mc rb bigbang/foobar --force || true
mc mb bigbang/foobar
mc ls bigbang/foobar
base64 /dev/urandom | head -c 10000000 > /tmp/file.txt
md5sum /tmp/file.txt > /tmp/filesig
mc cp /tmp/file.txt bigbang/foobar/file.txt
mc ls bigbang/foobar/file.txt
mc cp bigbang/foobar/file.txt /tmp/file.txt
mc rb bigbang/foobar --force
md5sum -c /tmp/filesig
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 4}}
{{- end }}
restartPolicy: Never
\ No newline at end of file
......@@ -6,9 +6,7 @@
replicas:
count: 1
accessKey: minio
secretKey: minio#123 # default key, change this!
hostname: bigbang.dev
nameOverride: ""
fullnameOverride: ""
......@@ -29,7 +27,7 @@ volumeClaimTemplate:
accessModes: ReadWriteOnce
storage: 1Gi # scale down for dev
minioRootCreds: minio-creds-secret
minioRootCreds: default-minio-creds-secret
imagePullSecrets: [ ]
......@@ -55,8 +53,18 @@ istio:
enabled: false
virtualService:
enabled: true
name: minio
annotations: {}
labels: {}
gateways:
- istio-system/main
hosts:
- minio.{{ .Values.hostname }}
service: ""
port: ""
monitoring:
enabled: false
namespace: monitoring
mcImage: registry1.dso.mil/ironbank/opensource/minio/mc:RELEASE.2021-03-23T05-46-11Z
\ No newline at end of file
......@@ -105,4 +105,4 @@ spec:
external:
url: {{ .Values.fileStore.url | default (printf "%s:9000" .Values.minio.service.nameOverride) }}
bucket: {{ .Values.fileStore.bucket | default "mattermost" }}
secret: {{ .Values.fileStore.secret | default "minio-creds-secret" }}
secret: {{ .Values.fileStore.secret | default "mattermost-objstore-creds" }}
......@@ -3,7 +3,7 @@ apiVersion: v1
kind: Secret
type: Opaque
metadata:
name: {{ include "mattermost.fullname" . }}-objstore-creds
name: mattermost-objstore-creds
namespace: {{ .Release.Namespace }}
labels:
{{ include "mattermost.labels" . | nindent 4 }}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment