make a tarbal via gitlab ci runners
new file: .gitlab-ci.yml modified: Makefile new file: make_tarball.sh
This commit is contained in:
parent
10855c35cc
commit
03ead82b0b
3 changed files with 26 additions and 1 deletions
19
.gitlab-ci.yml
Normal file
19
.gitlab-ci.yml
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
stages:
|
||||
- build
|
||||
- publish
|
||||
|
||||
build:
|
||||
stage: build
|
||||
script:
|
||||
- ./make_tarball.sh
|
||||
artifacts:
|
||||
paths:
|
||||
- www.unturf.com.tar.gz
|
||||
- commit-hash.txt
|
||||
expire_in: 1 month
|
||||
|
||||
publish:
|
||||
stage: publish
|
||||
script:
|
||||
# publish build to Salt Master
|
||||
- sudo /opt/salt-call-put-artifacts-onto-salt-master.sh
|
||||
3
Makefile
3
Makefile
|
|
@ -1,4 +1,5 @@
|
|||
|
||||
|
||||
http:
|
||||
# In the second shell, run a "mock" simple HTTP webserver to serve index.html:
|
||||
env/bin/python -m http.server 8000
|
||||
|
||||
|
|
|
|||
5
make_tarball.sh
Executable file
5
make_tarball.sh
Executable file
|
|
@ -0,0 +1,5 @@
|
|||
#tar -zcvf www.unturf.com.tar.gz output
|
||||
rm -rf .git
|
||||
cd ..; tar -zcvf www.unturf.com.tar.gz www.unturf.com; mv www.unturf.com.tar.gz www.unturf.com; cd www.unturf.com
|
||||
# create git-commit.txt to track this builds git commit hash.
|
||||
echo $GIT_COMMIT >> commit-hash.txt
|
||||
Loading…
Add table
Add a link
Reference in a new issue