Created
November 5, 2020 13:31
-
-
Save luxplanjay/74ac687277e20fc6f4de49b1c1fcb12d to your computer and use it in GitHub Desktop.
Деплой по ftp с github actions
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
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