Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Karakas
SWP_SS24_Wetterdaten_sammeln
Commits
0e8472e5
Commit
0e8472e5
authored
May 11, 2024
by
Karakas
Browse files
Update .gitlab-ci.yml file
parent
616ad661
Pipeline
#9165
passed with stages
in 58 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
.gitlab-ci.yml
View file @
0e8472e5
# This file is a template, and might need editing before it works on your project.
# To contribute improvements to CI/CD templates, please follow the Development guide at:
# https://docs.gitlab.com/ee/development/cicd/templates.html
# This specific template is located at:
# https://gitlab.com/gitlab-org/gitlab/-/blob/master/lib/gitlab/ci/templates/Nodejs.gitlab-ci.yml
# Official framework image. Look for the different tagged releases at:
# https://hub.docker.com/r/library/node/tags/
image
:
node:latest
image
:
node:18
# Use Node.js image for the pipeline
stages
:
-
build
-
deploy
# This folder is cached between builds
# https://docs.gitlab.com/ee/ci/yaml/index.html#cache
cache
:
paths
:
-
frontend/node_modules/
pages
:
stage
:
deploy
# Define jobs
build
:
stage
:
build
script
:
-
cd frontend
-
npm install
-
npm run start
-
echo "Deploying to https://transfer.hft-stuttgart.de/pages/$CI_PROJECT_PATH/"
-
cd frontend
# Change directory to the frontend folder
-
npm install
# Install dependencies
-
npm run build
# Build the React application
artifacts
:
paths
:
-
frontend/public
only
:
-
master
-
frontend/build/
# Specify the artifacts to be passed to the next stage
deploy
:
stage
:
deploy
script
:
-
echo "deploy to https://transfer.hft-stuttgart.de/pages/$CI_PROJECT_PATH/"
# Add your deployment script here, for example:
# - scp -r frontend/build/* user@your-server:/path/to/deploy
only
:
-
master
# Deploy only when changes are pushed to the master branch
\ No newline at end of file
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment