add changes to push files to server
Deploy to Production / deploy-to-production (push) Successful in 28s
Deploy to Production / deploy-to-production (push) Successful in 28s
This commit is contained in:
@@ -12,15 +12,14 @@ jobs:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Copy docker-compose.yml to server
|
||||
- name: Copy files to server
|
||||
uses: appleboy/scp-action@v0.1.7
|
||||
with:
|
||||
host: ${{ secrets.HOST }}
|
||||
username: ${{ secrets.USERNAME }}
|
||||
key: ${{ secrets.KEY }}
|
||||
source: "compose-file/docker-compose.yml"
|
||||
source: "configuration,docker-compose.yml,Dockerfile"
|
||||
target: "/home/${{ secrets.USERNAME }}/minecraft-server-ironveil"
|
||||
strip_components: 1
|
||||
|
||||
- name: Deploy and restart container
|
||||
uses: appleboy/ssh-action@v1.2.5
|
||||
|
||||
@@ -1,54 +0,0 @@
|
||||
name: Build and Publish Docker Image
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Download modpack from release
|
||||
run: |
|
||||
curl -L -H "Authorization: token ${{ secrets.GIT_PASSWORD }}" \
|
||||
-o modpack.zip \
|
||||
"https://git.cashew.network/${{ github.repository }}/releases/download/modpack-latest/modpack.zip"
|
||||
unzip -q modpack.zip -d modpack
|
||||
rm modpack.zip
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Log in to Docker Registry
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: git.cashew.network
|
||||
username: ${{ secrets.GIT_USERNAME }}
|
||||
password: ${{ secrets.GIT_PASSWORD }}
|
||||
|
||||
- name: Extract metadata
|
||||
id: meta
|
||||
uses: docker/metadata-action@v5
|
||||
with:
|
||||
images: git.cashew.network/${{ github.repository }}
|
||||
tags: |
|
||||
type=semver,pattern={{version}}
|
||||
type=semver,pattern={{major}}.{{minor}}
|
||||
type=semver,pattern={{major}}
|
||||
type=raw,value=latest
|
||||
|
||||
- name: Build and push Docker image
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
context: .
|
||||
push: true
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
cache-from: type=registry,ref=git.cashew.network/${{ github.repository }}:buildcache
|
||||
cache-to: type=registry,ref=git.cashew.network/${{ github.repository }}:buildcache,mode=max
|
||||
|
||||
Reference in New Issue
Block a user