Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
ShoppingCartProjectxyz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
snamdeo
ShoppingCartProjectxyz
Commits
a621581b
Commit
a621581b
authored
Sep 07, 2022
by
npagolu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update .gitlab-ci.yml
parent
9810fcb8
Pipeline
#2313
failed with stages
in 2 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
37 additions
and
13 deletions
+37
-13
.gitlab-ci.yml
.gitlab-ci.yml
+37
-13
No files found.
.gitlab-ci.yml
View file @
a621581b
before_script
:
-
apt-get update -qq && apt-get install -y -qq sqlite3 libsqlite3-dev nodejs
-
ruby -v
-
which ruby
-
gem install bundler --no-ri --no-rdoc
-
bundle install --jobs $(nproc) "${FLAGS[@]}"
rspec
:
script
:
-
bundle exec rspec
variables
:
RELEASE_NAME
:
"
ShoppingCartProjectxyz"
SERVICE_PORT
:
80
REGISTRY_URL
:
751503455312.dkr.ecr.us-east-1.amazonaws.com/pgdockrepo
stages
:
-
Build
-
ReleaseCleanup
-
ReleaseDeploy
-
Validation
rubocop
:
Build
:
stage
:
Build
script
:
-
bundle exec rubocop
\ No newline at end of file
-
$(aws ecr get-login --no-include-email --region us-east-1)
-
docker build -t 751503455312.dkr.ecr.us-east-1.amazonaws.com/pgdockrepo:$CI_PIPELINE_ID .
-
docker push 751503455312.dkr.ecr.us-east-1.amazonaws.com/pgdockrepo:$CI_PIPELINE_ID
ReleaseCleanup
:
stage
:
ReleaseCleanup
script
:
-
echo `pwd`
-
cd ./helm && /usr/local/bin/helm delete --purge $RELEASE_NAME && exit 0
allow_failure
:
true
ReleaseDeploy
:
stage
:
ReleaseDeploy
script
:
-
echo `pwd`
-
sed -i s/#BUILD_ID#/$CI_PIPELINE_ID/g ./helm/service/values.yaml
-
sed -i s/#SERVICE_PORT#/$SERVICE_PORT/g ./helm/service/values.yaml
-
cd ./helm && /usr/local/bin/helm install service --name $RELEASE_NAME
Validation
:
stage
:
Validation
script
:
-
sleep 45
-
if [ `curl -s -o /dev/null -I -w "%{http_code}" https://pgsandbox.altimetrik.com/$RELEASE_NAME/` = "200" ]; then exit 0; else exit 1; fi
allow_failure
:
false
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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