Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
courses
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
External wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Nene Barry
courses
Commits
0baad0e8
Verified
Commit
0baad0e8
authored
4 years ago
by
Laurent Heirendt
Browse files
Options
Downloads
Patches
Plain Diff
new deploy mechanism of website for courses
parent
8932d528
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
.gitlab-ci.yml
+31
-9
31 additions, 9 deletions
.gitlab-ci.yml
with
31 additions
and
9 deletions
.gitlab-ci.yml
+
31
−
9
View file @
0baad0e8
...
...
@@ -2,19 +2,44 @@ stages:
-
build
-
deploy
build
:
image
:
git-r3lab.uni.lu:4567/r3/docker/nodejs-yarn-grunt
build
index
:
image
:
alpine:3.1
stage
:
build
rules
:
-
if
:
$CI_COMMIT_BRANCH == "develop"
before_script
:
-
git clone https://git-r3lab.uni.lu/R3/school/courses.lcsb.uni.lu.git courses.lcsb.uni.lu
script
:
-
python .ci/generateIndex.py
build the website
:
image
:
git-r3lab.uni.lu:4567/r3/docker/jekyll-lcsb:1.4
stage
:
build
before_script
:
-
git submodule update --recursive --init
-
cd courses.lcsb.uni.lu
-
gem install bundler -v2.0.2
-
bundle install && bundle update jekyll-theme-lcsb-default && bundle update jekyll-theme-lcsb-frozen-components
script
:
-
bundle exec jekyll build -d site --config "_config.yml"
after_script
:
-
mv site ../.
-
cd ..
artifacts
:
expire_in
:
1 day
paths
:
-
site
variables
:
JEKYLL_ENV
:
production
build courses
:
image
:
git-r3lab.uni.lu:4567/r3/docker/nodejs-yarn-grunt
stage
:
build
rules
:
-
if
:
$CI_COMMIT_BRANCH == "develop"
before_script
:
-
git submodule update --recursive --init
script
:
-
bash .ci/deploy.sh
artifacts
:
expire_in
:
1 day
paths
:
...
...
@@ -22,9 +47,7 @@ build:
production
:
stage
:
deploy
image
:
alpine:3.1
before_script
:
-
'
which
ssh-agent
||
(
apk
add
--update
openssh
)'
-
eval $(ssh-agent -s)
...
...
@@ -33,9 +56,8 @@ production:
-
'
echo
-e
"Host
*\n\tStrictHostKeyChecking
no\n\n"
>
~/.ssh/config'
-
echo "$KNOWNHOSTS" > ~/.ssh/known_hosts
-
chmod 644 ~/.ssh/known_hosts
rules
:
-
if
:
'
$CI_COMMIT_BRANCH
==
"develop"'
script
:
-
scp -P $SSHPORT -r site/* $SSHCONNECT:~/web/latest
-
scp -P $SSHPORT -r public/* $SSHCONNECT:~/web/latest
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment