-
Notifications
You must be signed in to change notification settings - Fork 72
42 lines (38 loc) · 1.36 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# The main workflow should only run for the main site
on:
push:
branches:
- 'master'
# This workflow deploys the website to our main hosting
# Server. This should allow us to update the website
# by simply updating the website on Github.
name: Deploy Website
jobs:
web-deploy:
name: Deploy
# For now we will run this self hosted. We may choose
# to spin up a couple of these for extra reliability.
# Self-Hosted runners are setup at the organization
# Level.
#
# NOTE: I initially wanted to implement this with a
# fallback on Github-Hosted runners should ours go
# down (for any reason). This is not currently supported.
# Check back on this article for more information:
# https://github.community/t/self-hosted-runner-with-github-runner-as-backup-when-offline/17504/10
#
# If for some reason all runners seem to be offline, update the line to this:
runs-on: ubuntu-latest
# runs-on: self-hosted
steps:
# Pull latest code from GitHub
- name: Get latest code
uses: actions/checkout@v2
# Update files on the webserver using FTP.
- name: Sync Files on Web Server
uses: SamKirkland/[email protected]
with:
server: ${{ secrets.SERVER_NAME }}
username: ${{ secrets.FTP_USER }}
password: ${{ secrets.FTP_PASS }}
port: ${{ secrets.FTP_PORT }}