🚀 Deploy website on push #8
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- master | |
tags: | |
- "*" | |
name: 🚀 Deploy website on push | |
jobs: | |
web-deploy-ftp: | |
name: 🎉 Deploy | |
runs-on: ubuntu-latest | |
steps: | |
- name: 🚚 Get latest code | |
uses: actions/checkout@v4 | |
- name: 📂 Sync files to /www | |
uses: SamKirkland/[email protected] | |
with: | |
server: ftp.cluster023.hosting.ovh.net | |
username: sysarmy | |
password: ${{ secrets.ftp_password }} | |
server-dir: /www/ | |
build-and-push-docker-image: | |
name: 🐳 Build and Push Docker Image | |
runs-on: ubuntu-latest | |
steps: | |
- name: 🚚 Get latest code | |
uses: actions/checkout@v4 | |
- name: 🐳 Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
- name: 🔑 Log in to GitHub Container Registry | |
uses: docker/login-action@v2 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: 🛠 Build and Push Docker image | |
uses: docker/build-push-action@v5 | |
with: | |
context: .docker | |
push: true | |
tags: ghcr.io/${{ github.repository_owner }}/sysarmy-landing:latest |