feature/gitea-actions #2
							
								
								
									
										28
									
								
								.drone.yml
									
									
									
									
									
								
							
							
						
						
									
										28
									
								
								.drone.yml
									
									
									
									
									
								
							@@ -1,28 +0,0 @@
 | 
			
		||||
kind: pipeline
 | 
			
		||||
name: default
 | 
			
		||||
 | 
			
		||||
steps:
 | 
			
		||||
  - name: build and publish monica docker image
 | 
			
		||||
    image: plugins/docker
 | 
			
		||||
    settings:
 | 
			
		||||
      registry: gitea.sikorski.cloud
 | 
			
		||||
      username: rogersik
 | 
			
		||||
      password:
 | 
			
		||||
        from_secret: "gitea_token"
 | 
			
		||||
      repo: gitea.sikorski.cloud/rogersik/docker-monica
 | 
			
		||||
      tags: latest,4
 | 
			
		||||
      cache_from: gitea.sikorski.cloud/rogersik/docker-monica:latest
 | 
			
		||||
 | 
			
		||||
  - name: notify
 | 
			
		||||
    image: drillster/drone-email
 | 
			
		||||
    settings:
 | 
			
		||||
      host: mailcow.basecom.de
 | 
			
		||||
      from:
 | 
			
		||||
        from_secret: "Notifications_Address"
 | 
			
		||||
      username:
 | 
			
		||||
        from_secret: "Notifications_Address"
 | 
			
		||||
      password:
 | 
			
		||||
        from_secret: "Notifications_Address_Password"
 | 
			
		||||
      recipients: [roger@sikorski.cloud]
 | 
			
		||||
    when:
 | 
			
		||||
      status: [failure]
 | 
			
		||||
							
								
								
									
										31
									
								
								.gitea/workflows/dev.yaml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										31
									
								
								.gitea/workflows/dev.yaml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,31 @@
 | 
			
		||||
name: docker-monica-build mr
 | 
			
		||||
 | 
			
		||||
on:
 | 
			
		||||
  push:
 | 
			
		||||
    branches-ignore:
 | 
			
		||||
      - main
 | 
			
		||||
 | 
			
		||||
jobs:
 | 
			
		||||
  Dockerfile lint:
 | 
			
		||||
    runs-on: k3s
 | 
			
		||||
    steps:
 | 
			
		||||
      - uses: actions/checkout@v3
 | 
			
		||||
      - uses: hadolint/hadolint-action@v3.1.0
 | 
			
		||||
        with:
 | 
			
		||||
          dockerfile: Dockerfile
 | 
			
		||||
 | 
			
		||||
  build:
 | 
			
		||||
    needs: Dockerfile lint
 | 
			
		||||
    runs-on: docker
 | 
			
		||||
    steps:
 | 
			
		||||
      - uses: actions/checkout@v3
 | 
			
		||||
      - name: Pull Docker Image for caching
 | 
			
		||||
        run: docker pull gitea.sikorski.cloud/rogersik/monica:development || exit 0
 | 
			
		||||
      - name: Build docker image
 | 
			
		||||
        run: |
 | 
			
		||||
          docker build . \
 | 
			
		||||
            --cache-from gitea.sikorski.cloud/rogersik/monica:development \
 | 
			
		||||
            --file Dockerfile \
 | 
			
		||||
            --tag gitea.sikorski.cloud/rogersik/monica:development
 | 
			
		||||
      - name: Push docker image
 | 
			
		||||
        run: docker push gitea.sikorski.cloud/rogersik/monica --all-tags
 | 
			
		||||
							
								
								
									
										34
									
								
								.gitea/workflows/main.yaml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										34
									
								
								.gitea/workflows/main.yaml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,34 @@
 | 
			
		||||
---
 | 
			
		||||
name: docker-monica-build main
 | 
			
		||||
on:
 | 
			
		||||
  push:
 | 
			
		||||
    branches:
 | 
			
		||||
      - main
 | 
			
		||||
  schedule:
 | 
			
		||||
    - cron: "0 6 * * SUN"
 | 
			
		||||
 | 
			
		||||
jobs:
 | 
			
		||||
  Dockerfile lint:
 | 
			
		||||
    runs-on: k3s
 | 
			
		||||
    steps:
 | 
			
		||||
      - uses: actions/checkout@v3
 | 
			
		||||
      - uses: hadolint/hadolint-action@v3.1.0
 | 
			
		||||
        with:
 | 
			
		||||
          dockerfile: Dockerfile
 | 
			
		||||
 | 
			
		||||
  build:
 | 
			
		||||
    needs: Dockerfile lint
 | 
			
		||||
    runs-on: docker
 | 
			
		||||
    steps:
 | 
			
		||||
      - uses: actions/checkout@v3
 | 
			
		||||
      - name: Pull Docker Image for caching
 | 
			
		||||
        run: docker pull gitea.sikorski.cloud/rogersik/monica:latest || exit 0
 | 
			
		||||
      - name: Build docker image
 | 
			
		||||
        run: |
 | 
			
		||||
          docker build . \
 | 
			
		||||
            --cache-from gitea.sikorski.cloud/rogersik/monica:latest \
 | 
			
		||||
            --file Dockerfile \
 | 
			
		||||
            --tag gitea.sikorski.cloud/rogersik/monica:latest
 | 
			
		||||
            --tag gitea.sikorski.cloud/rogersik/monica:4
 | 
			
		||||
      - name: Push docker image
 | 
			
		||||
        run: docker push gitea.sikorski.cloud/rogersik/monica --all-tags
 | 
			
		||||
							
								
								
									
										2
									
								
								.hadolint.yaml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								.hadolint.yaml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,2 @@
 | 
			
		||||
ignored:
 | 
			
		||||
  - DL3008 # no need to pin versions
 | 
			
		||||
@@ -1,10 +1,11 @@
 | 
			
		||||
# https://hub.docker.com/_/monica
 | 
			
		||||
FROM monica:4
 | 
			
		||||
 | 
			
		||||
# Use the default production configuration
 | 
			
		||||
RUN mv "$PHP_INI_DIR/php.ini-production" "$PHP_INI_DIR/php.ini"
 | 
			
		||||
# increase php upload limit
 | 
			
		||||
RUN sed -i 's/upload_max_filesize = 2M/upload_max_filesize = 50M/' "$PHP_INI_DIR/php.ini"
 | 
			
		||||
RUN \
 | 
			
		||||
  # Use the default production configuration
 | 
			
		||||
  mv "$PHP_INI_DIR/php.ini-production" "$PHP_INI_DIR/php.ini" && \
 | 
			
		||||
  # increase php upload limit
 | 
			
		||||
  sed -i 's/upload_max_filesize = 2M/upload_max_filesize = 50M/' "$PHP_INI_DIR/php.ini"
 | 
			
		||||
 | 
			
		||||
# supervisord dependencies
 | 
			
		||||
RUN apt-get update && \
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user