Compare commits
5 commits
a623d96fb9
...
05aebc55ae
Author | SHA1 | Date | |
---|---|---|---|
05aebc55ae | |||
c0c28aa679 | |||
7911f157bd | |||
0b2e557e3b | |||
c1273bb468 |
2 changed files with 37 additions and 73 deletions
|
@ -22,20 +22,51 @@ jobs:
|
||||||
run: npm run build:de
|
run: npm run build:de
|
||||||
- uses: actions/upload-artifact@v3
|
- uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: website
|
name: build
|
||||||
path: dist/
|
path: dist/
|
||||||
deploy-dev:
|
deploy-dev:
|
||||||
needs: [website]
|
name: Deploy Dev Website
|
||||||
runs-on: docker
|
runs-on: docker
|
||||||
container:
|
container:
|
||||||
image: node:lts-alpine
|
image: node:lts-alpine
|
||||||
if:
|
needs: [build]
|
||||||
- github.ref == 'refs/heads/develop'
|
if: github.ref == 'refs/heads/develop'
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/download-artifact@v3
|
- uses: actions/download-artifact@v3
|
||||||
- name: Install Dependencies
|
- name: Install Dependencies
|
||||||
run: which lftp || ( apk --update add lftp )
|
run: which lftp || ( apk --update add lftp )
|
||||||
- name: Deploy English Version
|
- name: Deploy English Version
|
||||||
run: lftp -e "set ftp:ssl-force true; set ssl:verify-certificate no; mirror -R ./dist/en/ dev.samuel-philipp.com/; bye" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOST
|
run: lftp -e "set ftp:ssl-force true; set ssl:verify-certificate no; mirror -R ./build/en/ dev.samuel-philipp.com/; bye" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOST
|
||||||
|
env:
|
||||||
|
FTP_HOST: ${{ secrets.FTP_HOST }}
|
||||||
|
FTP_USERNAME: ${{ secrets.FTP_USERNAME }}
|
||||||
|
FTP_PASSWORD: ${{ secrets.FTP_PASSWORD }}
|
||||||
- name: Deploy German Version
|
- name: Deploy German Version
|
||||||
run: lftp -e "set ftp:ssl-force true; set ssl:verify-certificate no; mirror -R ./dist/de/ dev.samuel-philipp.de/; bye" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOST
|
run: lftp -e "set ftp:ssl-force true; set ssl:verify-certificate no; mirror -R ./build/de/ dev.samuel-philipp.de/; bye" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOST
|
||||||
|
env:
|
||||||
|
FTP_HOST: ${{ secrets.FTP_HOST }}
|
||||||
|
FTP_USERNAME: ${{ secrets.FTP_USERNAME }}
|
||||||
|
FTP_PASSWORD: ${{ secrets.FTP_PASSWORD }}
|
||||||
|
deploy:
|
||||||
|
name: Deploy Website
|
||||||
|
runs-on: docker
|
||||||
|
container:
|
||||||
|
image: node:lts-alpine
|
||||||
|
needs: [build]
|
||||||
|
if: github.ref == 'refs/heads/main'
|
||||||
|
steps:
|
||||||
|
- uses: actions/download-artifact@v3
|
||||||
|
- name: Install Dependencies
|
||||||
|
run: which lftp || ( apk --update add lftp )
|
||||||
|
- name: Deploy English Version
|
||||||
|
run: lftp -e "set ftp:ssl-force true; set ssl:verify-certificate no; mirror -R ./build/en/ samuel-philipp.com/; bye" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOST
|
||||||
|
env:
|
||||||
|
FTP_HOST: ${{ secrets.FTP_HOST }}
|
||||||
|
FTP_USERNAME: ${{ secrets.FTP_USERNAME }}
|
||||||
|
FTP_PASSWORD: ${{ secrets.FTP_PASSWORD }}
|
||||||
|
- name: Deploy German Version
|
||||||
|
run: lftp -e "set ftp:ssl-force true; set ssl:verify-certificate no; mirror -R ./build/de/ samuel-philipp.de/; bye" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOST
|
||||||
|
env:
|
||||||
|
FTP_HOST: ${{ secrets.FTP_HOST }}
|
||||||
|
FTP_USERNAME: ${{ secrets.FTP_USERNAME }}
|
||||||
|
FTP_PASSWORD: ${{ secrets.FTP_PASSWORD }}
|
||||||
|
|
|
@ -1,67 +0,0 @@
|
||||||
pipeline:
|
|
||||||
build:
|
|
||||||
image: node:lts
|
|
||||||
commands:
|
|
||||||
- npm install
|
|
||||||
- npm run build
|
|
||||||
build-de:
|
|
||||||
image: node:lts
|
|
||||||
commands:
|
|
||||||
- npm install
|
|
||||||
- npm run build:de
|
|
||||||
deploy-dev:
|
|
||||||
image: alpine
|
|
||||||
secrets:
|
|
||||||
- FTP_HOST
|
|
||||||
- FTP_USERNAME
|
|
||||||
- FTP_PASSWORD
|
|
||||||
commands:
|
|
||||||
- which lftp || ( apk --update add lftp )
|
|
||||||
- lftp -e "set ftp:ssl-force true; set ssl:verify-certificate no; mirror -R ./dist/en/ dev.samuel-philipp.com/; bye" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOST
|
|
||||||
when:
|
|
||||||
branch:
|
|
||||||
- develop
|
|
||||||
event:
|
|
||||||
- push
|
|
||||||
deploy-dev-de:
|
|
||||||
image: alpine
|
|
||||||
secrets:
|
|
||||||
- FTP_HOST
|
|
||||||
- FTP_USERNAME
|
|
||||||
- FTP_PASSWORD
|
|
||||||
commands:
|
|
||||||
- which lftp || ( apk --update add lftp )
|
|
||||||
- lftp -e "set ftp:ssl-force true; set ssl:verify-certificate no; mirror -R ./dist/de/ dev.samuel-philipp.de/; bye" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOST
|
|
||||||
when:
|
|
||||||
branch:
|
|
||||||
- develop
|
|
||||||
event:
|
|
||||||
- push
|
|
||||||
deploy:
|
|
||||||
image: alpine
|
|
||||||
secrets:
|
|
||||||
- FTP_HOST
|
|
||||||
- FTP_USERNAME
|
|
||||||
- FTP_PASSWORD
|
|
||||||
commands:
|
|
||||||
- which lftp || ( apk --update add lftp )
|
|
||||||
- lftp -e "set ftp:ssl-force true; set ssl:verify-certificate no; mirror -R ./dist/en/ samuel-philipp.com/; bye" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOST
|
|
||||||
when:
|
|
||||||
branch:
|
|
||||||
- main
|
|
||||||
event:
|
|
||||||
- push
|
|
||||||
deploy-de:
|
|
||||||
image: alpine
|
|
||||||
secrets:
|
|
||||||
- FTP_HOST
|
|
||||||
- FTP_USERNAME
|
|
||||||
- FTP_PASSWORD
|
|
||||||
commands:
|
|
||||||
- which lftp || ( apk --update add lftp )
|
|
||||||
- lftp -e "set ftp:ssl-force true; set ssl:verify-certificate no; mirror -R ./dist/de/ samuel-philipp.de/; bye" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOST
|
|
||||||
when:
|
|
||||||
branch:
|
|
||||||
- main
|
|
||||||
event:
|
|
||||||
- push
|
|
Loading…
Reference in a new issue