commit
06a6f6cb38
2 changed files with 103 additions and 2 deletions
37
.gitea/workflows/deploy.yml
Normal file
37
.gitea/workflows/deploy.yml
Normal file
|
|
@ -0,0 +1,37 @@
|
||||||
|
name: Deploy Docker Container
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_run:
|
||||||
|
workflows: ["Build and Push Docker Image"]
|
||||||
|
types:
|
||||||
|
- completed
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
- dev
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
deploy:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
if: ${{ github.event.workflow_run.conclusion == 'success' }}
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
ref: ${{ github.event.workflow_run.head_branch }}
|
||||||
|
|
||||||
|
- name: Deploy to Docker
|
||||||
|
run: |
|
||||||
|
mkdir -p ~/.ssh
|
||||||
|
echo "${{ secrets.DEPLOY_KEY }}" > ~/.ssh/deploy_key
|
||||||
|
chmod 600 ~/.ssh/deploy_key
|
||||||
|
ssh-keyscan -H ${{ secrets.DEPLOY_HOST }} >> ~/.ssh/known_hosts
|
||||||
|
|
||||||
|
BRANCH="${{ github.event.workflow_run.head_branch }}"
|
||||||
|
DEPLOY_PATH="${{ secrets.DEPLOY_PATH }}"
|
||||||
|
|
||||||
|
ssh -i ~/.ssh/deploy_key ${{ secrets.DEPLOY_USER }}@${{ secrets.DEPLOY_HOST }} << EOF
|
||||||
|
cd ${DEPLOY_PATH}
|
||||||
|
docker-compose pull lcc-app-${BRANCH}
|
||||||
|
docker-compose --profile ${BRANCH} up -d lcc-app-${BRANCH}
|
||||||
|
EOF
|
||||||
|
|
@ -1,3 +1,67 @@
|
||||||
{
|
{
|
||||||
"$schema": "https://docs.renovatebot.com/renovate-schema.json"
|
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
|
||||||
|
"extends": [
|
||||||
|
"config:recommended"
|
||||||
|
],
|
||||||
|
"timezone": "Europe/Berlin",
|
||||||
|
"schedule": [
|
||||||
|
"before 6am on monday"
|
||||||
|
],
|
||||||
|
"labels": [
|
||||||
|
"dependencies"
|
||||||
|
],
|
||||||
|
"prConcurrentLimit": 5,
|
||||||
|
"packageRules": [
|
||||||
|
{
|
||||||
|
"description": "Gruppiere Spring Boot Dependencies",
|
||||||
|
"groupName": "Spring Boot",
|
||||||
|
"matchPackagePrefixes": [
|
||||||
|
"org.springframework.boot",
|
||||||
|
"org.springframework"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "Gruppiere Vue.js Ecosystem",
|
||||||
|
"groupName": "Vue.js",
|
||||||
|
"matchPackagePrefixes": [
|
||||||
|
"vue",
|
||||||
|
"@vue"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "Auto-merge für Minor und Patch Updates",
|
||||||
|
"matchUpdateTypes": [
|
||||||
|
"minor",
|
||||||
|
"patch"
|
||||||
|
],
|
||||||
|
"automerge": true,
|
||||||
|
"automergeType": "pr"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "Major Updates manuell prüfen",
|
||||||
|
"matchUpdateTypes": [
|
||||||
|
"major"
|
||||||
|
],
|
||||||
|
"automerge": false,
|
||||||
|
"labels": [
|
||||||
|
"dependencies",
|
||||||
|
"major-update"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "Docker Base Images wöchentlich prüfen",
|
||||||
|
"matchDatasources": [
|
||||||
|
"docker"
|
||||||
|
],
|
||||||
|
"schedule": [
|
||||||
|
"before 6am on monday"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"vulnerabilityAlerts": {
|
||||||
|
"enabled": true,
|
||||||
|
"labels": [
|
||||||
|
"security"
|
||||||
|
]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Loading…
Add table
Reference in a new issue