Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
ippidb-web
Manage
Activity
Members
Labels
Code
Merge requests
1
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Operate
Environments
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
iPPIDB
ippidb-web
Commits
f52e3dc0
Commit
f52e3dc0
authored
7 years ago
by
Hervé MENAGER
Browse files
Options
Downloads
Patches
Plain Diff
WIP on ansible deployment
Former-commit-id: 80c84bd711c4f3d58ebf37c9cfca4f2977ac7968
parent
68b16145
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
ansible/deploy.yaml
+3
-2
3 additions, 2 deletions
ansible/deploy.yaml
ansible/system.yaml
+31
-1
31 additions, 1 deletion
ansible/system.yaml
with
34 additions
and
3 deletions
ansible/deploy.yaml
+
3
−
2
View file @
f52e3dc0
...
...
@@ -7,14 +7,15 @@
-
name
:
pull branch master
git
:
repo=git@gitlab.pasteur.fr:odoppelt/iPPIDB.git
dest=iPPIDB
dest=
/home/ippidb/
iPPIDB
accept_hostkey=yes
-
hosts
:
all
become
:
yes
gather_facts
:
no
tasks
:
-
name
:
install python requirements
pip
:
requirements=
{{ repo_dir }}
/requirements.txt extra_args=--upgrade
pip
:
requirements=
/home/ippidb/iPPIDB/ippisite
/requirements.txt extra_args=--upgrade
executable=pip3
-
hosts
:
all
become
:
yes
...
...
This diff is collapsed.
Click to expand it.
ansible/system.yaml
+
31
−
1
View file @
f52e3dc0
...
...
@@ -13,6 +13,36 @@
-
name
:
install git
yum
:
name=git state=present
become
:
true
-
name
:
Add repository
become
:
true
yum_repository
:
name
:
epel
description
:
EPEL YUM repo
gpgcheck
:
no
baseurl
:
https://download.fedoraproject.org/pub/epel/$releasever/$basearch/
-
name
:
install python3
yum
:
name=python34 state=present update_cache=yes
become
:
true
-
name
:
install python3 development package
yum
:
name=python34-devel state=present update_cache=yes
become
:
true
-
name
:
install setuptools
yum
:
name=python34-setuptools state=present update_cache=yes
become
:
true
-
name
:
install pip
shell
:
"
easy_install-3.4
pip"
become
:
true
-
name
:
install graphviz
yum
:
name=graphviz state=present update_cache=yes
become
:
true
-
name
:
install graphviz-devel
yum
:
name=graphviz-devel state=present update_cache=yes
become
:
true
-
name
:
install the 'Development tools' package group
yum
:
name
:
"
@Development
tools"
state
:
present
become
:
true
-
name
:
Cat deployer's user public key
shell
:
"
cat
/home/{{
deploy_user_name
}}/.ssh/id_rsa.pub"
register
:
key_value
...
...
@@ -24,5 +54,5 @@
shell
:
"
cat
/home/{{
deploy_user_name
}}/ssh_key.json"
become
:
true
-
name
:
Upload deploy keys to gitlab
shell
:
"
curl
-X
POST
-H
'Accept:
application/json'
-H
'Content-type:
application/json'
-H
'PRIVATE-TOKEN:
{{
repo_api_token
}}'
--data-binary
@/home/{{
deploy_user_name
}}/ssh_key.json
https://gitlab.pasteur.fr/api/v3/projects/
odoppelt/iPPIDB
/keys"
shell
:
"
curl
-X
POST
-H
'Accept:
application/json'
-H
'Content-type:
application/json'
-H
'PRIVATE-TOKEN:
{{
repo_api_token
}}'
--data-binary
@/home/{{
deploy_user_name
}}/ssh_key.json
https://gitlab.pasteur.fr/api/v3/projects/
198
/keys"
become
:
true
This diff is collapsed.
Click to expand it.
Preview
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!
Save comment
Cancel
Please
register
or
sign in
to comment