Skip to content
Snippets Groups Projects
Commit 5cb25989 authored by Robotka István Adrián's avatar Robotka István Adrián
Browse files

add ci config

parent 5ed8d7cf
Branches
No related tags found
2 merge requests!3CI,!2add ci config
Pipeline #5290 failed
# Ordering stages and jobs
stages:
- build
- test
- deploy
cache:
key: $CI_COMMIT_REF_SLUG
paths:
- node_modules/
build:
stage: build
image: node:14
script:
- npm ci
- CI=false npm run build
artifacts:
expire_in: 1 week
paths:
- build/
editorconfig:
stage: build
image:
name: odannyc/eclint
entrypoint: [""]
dependencies: [] # job can start immediately
allow_failure: true
script:
- eclint check $(git ls-files)
# hidden job template, not gonna run
.ftp:
stage: deploy
image: ubuntu:focal
variables:
#ENV: must_be_filled
HOST: "${FTP_HOST_$ENV}"
USER: "${FTP_USER_$ENV}"
PASS: "${FTP_PASS_$ENV}"
script:
- apt-get update && apt-get install -y lftp ca-certificates
- |
FTP_CMD="lftp -e \"set dns:order 'inet inet6';
mirror -R site/ public/ ; quit\"
-u $FTP_USER,$FTP_PASS $FTP_HOST"
- echo "$FTP_CMD"
- $FTP_CMD
except:
- tags
ftp-prod:
extends: .ftp
environment:
url: https://schdesign.hu/
variables:
ENV: prod
only:
- master
ftp-staging:
extends: .ftp
environment:
url: https://kiscica.schdesign.hu/
variables:
ENV: staging
only:
- ci
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment