Compare commits

...

5 Commits

Author SHA1 Message Date
Tobias Trabelsi 4d36cd468f
Merge pull request #30 from Lerentis/Lerentis/issue29
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/tag Build is passing Details
2023-06-24 18:38:39 +02:00
Tobias Trabelsi 6f099c4bf2
fix bw installation -.-
continuous-integration/drone/push Build is passing Details
Fixes #29
2023-06-24 18:32:55 +02:00
Tobias Trabelsi aa015cc7ba update dependencies 2023-05-31 10:17:59 +02:00
Tobias Trabelsi 2de9bbb0bf
Merge pull request #28 from Lerentis/dependabot/github_actions/mikefarah/yq-4.34.1
Bump mikefarah/yq from 4.33.3 to 4.34.1
2023-05-31 09:40:00 +02:00
dependabot[bot] 4505f3985c
Bump mikefarah/yq from 4.33.3 to 4.34.1
Bumps [mikefarah/yq](https://github.com/mikefarah/yq) from 4.33.3 to 4.34.1.
- [Release notes](https://github.com/mikefarah/yq/releases)
- [Changelog](https://github.com/mikefarah/yq/blob/master/release_notes.txt)
- [Commits](https://github.com/mikefarah/yq/compare/v4.33.3...v4.34.1)

---
updated-dependencies:
- dependency-name: mikefarah/yq
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-05-29 07:00:59 +00:00
5 changed files with 18 additions and 14 deletions

View File

@ -36,7 +36,7 @@ jobs:
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
- name: Get app version from chart
uses: mikefarah/yq@v4.33.3
uses: mikefarah/yq@v4.34.1
id: app_version
with:
cmd: yq '.appVersion' charts/bitwarden-crd-operator/Chart.yaml

4
.gitignore vendored
View File

@ -165,4 +165,6 @@ include
lib
lib64
myvalues.yaml
myvalues.yaml
.vscode

View File

@ -1,13 +1,13 @@
FROM alpine:3.17.3
FROM alpine:3.18.0
LABEL org.opencontainers.image.source=https://github.com/Lerentis/bitwarden-crd-operator
LABEL org.opencontainers.image.description="Kubernetes Operator to create k8s secrets from bitwarden"
LABEL org.opencontainers.image.licenses=MIT
ARG PYTHON_VERSION=3.10.11-r0
ARG PIP_VERSION=22.3.1-r1
ARG GCOMPAT_VERSION=1.1.0-r0
ARG LIBCRYPTO_VERSION=3.0.8-r4
ARG PYTHON_VERSION=3.11.4-r0
ARG PIP_VERSION=23.1.2-r0
ARG GCOMPAT_VERSION=1.1.0-r1
ARG LIBCRYPTO_VERSION=3.1.0-r4
ARG BW_VERSION=2023.1.0
COPY requirements.txt /requirements.txt
@ -24,6 +24,8 @@ RUN set -eux; \
cd /tmp; \
wget https://github.com/bitwarden/clients/releases/download/cli-v${BW_VERSION}/bw-linux-${BW_VERSION}.zip; \
unzip /tmp/bw-linux-${BW_VERSION}.zip; \
mv /tmp/bw /usr/local/bin/bw; \
chmod +x /usr/local/bin/bw; \
;; \
*) \
echo "Unsupported arch: ${ARCH}"; \
@ -35,7 +37,7 @@ RUN set -eux; \
adduser -S -D -u 1000 -G bw-operator bw-operator; \
mkdir -p /home/bw-operator; \
chown -R bw-operator /home/bw-operator; \
apk add gcc musl-dev libstdc++ gcompat=${GCOMPAT_VERSION} python3=${PYTHON_VERSION} py3-pip=${PIP_VERSION} libcrypto3=${LIBCRYPTO_VERSION} libssl3=${LIBCRYPTO_VERSION}; \
apk add gcc musl-dev libstdc++ gcompat=${GCOMPAT_VERSION} python3=${PYTHON_VERSION} py3-pip=${PIP_VERSION} libcrypto3=${LIBCRYPTO_VERSION}; \
pip install -r /requirements.txt --no-warn-script-location; \
rm /requirements.txt; \
apk del --purge gcc musl-dev libstdc++;

View File

@ -4,9 +4,9 @@ description: Deploy the Bitwarden CRD Operator
type: application
version: "v0.7.2"
version: "v0.7.4"
appVersion: "0.6.2"
appVersion: "0.6.4"
keywords:
- operator
@ -96,7 +96,7 @@ annotations:
artifacthub.io/containsSecurityUpdates: "false"
artifacthub.io/changes: |
- kind: fixed
description: "Fallback to npm package on ARM as native bitwarden cli package is not compatible with ARM"
description: "Fixed bitwarden installation"
artifacthub.io/images: |
- name: bitwarden-crd-operator
image: ghcr.io/lerentis/bitwarden-crd-operator:0.6.2
image: ghcr.io/lerentis/bitwarden-crd-operator:0.6.4

View File

@ -32,9 +32,9 @@ def command_wrapper(logger, command, use_success: bool = True):
shell=True,
env=system_env)
out, err = sp.communicate()
resp = json.loads(out.decode(encoding='UTF-8'))
if "DEBUG" in system_env:
logger.info(resp)
logger.info(out.decode(encoding='UTF-8'))
resp = json.loads(out.decode(encoding='UTF-8'))
if resp["success"] != None and (not use_success or (use_success and resp["success"] == True)):
return resp
logger.warn(resp)