From c45d790089be2afe00b91dc2f6e6d965b7709687 Mon Sep 17 00:00:00 2001 From: LordMathis Date: Wed, 29 Nov 2023 22:24:47 +0100 Subject: [PATCH] Create action --- .gitea/workflows/release.yaml | 31 +++++++++++++++++++++++++++++++ README.md | 2 +- 2 files changed, 32 insertions(+), 1 deletion(-) create mode 100644 .gitea/workflows/release.yaml diff --git a/.gitea/workflows/release.yaml b/.gitea/workflows/release.yaml new file mode 100644 index 0000000..22bfbd9 --- /dev/null +++ b/.gitea/workflows/release.yaml @@ -0,0 +1,31 @@ +name: Build website container +on: + push: + branches: + - main + +jobs: + build: + name: Build image + runs-on: ubuntu-latest + container: ghcr.io/catthehacker/ubuntu:act-latest + env: + IMAGE_NAME: mlflow + REGISTRY: git.namesny.com + REPO_OWNER: cluster + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Login to Registry + uses: docker/login-action@v3 + with: + registry: git.namesny.com + username: ${{ gitea.actor }} + password: ${{ secrets.REGISTRY_TOKEN }} + - name: Build and push + run: | + VERSION=$(cat requirements.txt | grep mlflow | cut -d'=' -f3) + docker build -t ${REGISTRY}/${REPO_OWNER}/${IMAGE_NAME}:${VERSION} -t ${REGISTRY}/${REPO_OWNER}/${IMAGE_NAME}:latest . + docker push ${REGISTRY}/${REPO_OWNER}/${IMAGE_NAME}:${VERSION} + docker push ${REGISTRY}/${REPO_OWNER}/${IMAGE_NAME}:latest + \ No newline at end of file diff --git a/README.md b/README.md index 3df953d..ca4b48b 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,3 @@ -# mlflow +# Mlflow Mlflow Docker container with support for postgres and s3 storage \ No newline at end of file