Skip to content
Snippets Groups Projects
Commit 1334f931 authored by William E Warriner's avatar William E Warriner
Browse files

target s3 bucket

parent 2ef79132
Branches feat-ci-to-lts
No related tags found
1 merge request!7CI/CD targeting LTS to publish syllabus
Pipeline #8327 failed with stage
build-job: stages:
stage: build - build
tags: - deploy
- rcds
script:
- echo "Hello, $GITLAB_USER_LOGIN"
test-job1: build:
stage: test stage: build
tags: script:
- rcds # We simulate a build phase by manually creating files in a build folder
script: # An example would be using `yarn build` to build a react project that would create static files in a build or public folder
- echo "This job tests something" - mkdir -p public && cp data_science_journal_club_syllabus.html public/syllabus.html
artifacts:
when: on_success
paths:
- build/
expire_in: 20 mins
test-job2:
stage: test
tags:
- rcds
script:
- echo "This job tests something, but takes more time than test-job1"
- echo "Sleeps for 20 seconds"
- sleep 20
deploy-prod: deploy:
stage: deploy stage: deploy
tags: needs:
- rcds - build
script: image: registry.gitlab.com/gitlab-org/cloud-deploy/aws-base:latest
- echo "This job deploys something from $CI_COMMIT_BRANCH branch." rules:
environment: production - if: $CI_COMMIT_TAG # Run this job when a tag is created
script:
- echo "Running deploy"
- aws s3 cp --endpoint-url=https://s3.lts.rc.uab.edu ./public/syllabus.html s3://$S3_BUCKET/ --recursive
- echo "Deployment successful"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment