Skip to content

Commit

Permalink
paritytech/ci_cd#852: Remove misused artifact instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
Oleg Plakida committed Aug 24, 2023
1 parent ee56564 commit aa59f4c
Showing 1 changed file with 16 additions and 20 deletions.
36 changes: 16 additions & 20 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,45 +58,41 @@ variables:
- if: $CI_COMMIT_REF_NAME == "main"
- if: $CI_COMMIT_REF_NAME =~ /^v[0-9]+\.[0-9]+.*$/ # i.e. v1.0, v2.1rc1

# telling gitlab to collect artifacts from artifacts/ folder to path it to other jobs
.collect-artifacts: &collect-artifacts
artifacts:
name: "${CI_JOB_NAME}_${CI_COMMIT_REF_NAME}"
when: on_success
expire_in: 2 days
paths:
- artifacts/

test:
stage: test
<<: *kubernetes-env
<<: *common-refs
<<: *collect-artifacts
cache:
- key:
files:
- package-lock.json
- paths:
- packages/
- package.json
- package-lock.json
script:
- mkdir -p artifacts
- cd javascript
- npm install
# - npm run test
- echo testme
- cp -r packages/ ../artifacts/
- cp package.json ../artifacts/
- cp package-lock.json ../artifacts/
- ls -ltr ../artifacts/*

build:
stage: build
<<: *kubernetes-env
<<: *common-refs
<<: *collect-artifacts
cache:
- key:
files:
- package-lock.json
- paths:
- packages/
- package.json
- package-lock.json
script:
- mkdir -p artifacts
- cd javascript
- npm install
- npm run clean
- npm run build
- cp -r packages/ ../artifacts/
- cp package.json ../artifacts/
- cp package-lock.json ../artifacts/

# template task for building and pushing an image
.build-push-docker-image: &build-push-docker-image
Expand Down

0 comments on commit aa59f4c

Please sign in to comment.