Skip to content

Instantly share code, notes, and snippets.

@luxplanjay
Created November 5, 2020 13:31
Show Gist options
  • Save luxplanjay/74ac687277e20fc6f4de49b1c1fcb12d to your computer and use it in GitHub Desktop.
Save luxplanjay/74ac687277e20fc6f4de49b1c1fcb12d to your computer and use it in GitHub Desktop.
Деплой по ftp с github actions
name: Node.js CI
on:
push:
branches:
- master
jobs:
FTP-Deploy-Action:
name: Build and publish via FTP
runs-on: ubuntu-latest
steps:
- name: Checkout files
uses: actions/[email protected]
with:
fetch-depth: 2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Build project
run: |
npm install
npm run build --if-present
- name: Deploy via FTP
uses: SamKirkland/[email protected]
with:
ftp-server: тут_путь_на_хостинге
ftp-username: ${{ secrets.FTP_USERNAME }}
ftp-password: ${{ secrets.FTP_PASSWORD }}
local-dir: build
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment