Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
Satnogs Ansible
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
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
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
PARENT Aldric
Satnogs Ansible
Commits
8ceb4150
Commit
8ceb4150
authored
5 years ago
by
Vasilis Tsiligiannis
Browse files
Options
Downloads
Patches
Plain Diff
satnogs-client: Recreate virtualenv on Python mismatches
Signed-off-by:
Vasilis Tsiligiannis
<
acinonyx@openwrt.gr
>
parent
361a219d
Branches
Branches containing commit
Tags
201912112036
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
roles/satnogs-client/tasks/main.yml
+6
-1
6 additions, 1 deletion
roles/satnogs-client/tasks/main.yml
with
6 additions
and
1 deletion
roles/satnogs-client/tasks/main.yml
+
6
−
1
View file @
8ceb4150
...
...
@@ -22,6 +22,11 @@
with_items
:
'
{{
satnogs_client_packages
}}'
notify
:
-
Restart satnogs-client service
-
name
:
Get virtualenv Python version
# noqa 306
shell
:
'
/var/lib/{{
satnogs_client_user
}}/bin/python
--version
2>&1
|
awk
'
'
/^Python/
{
print
$2
}'
'
'
become
:
true
register
:
res_python_version
changed_when
:
false
-
name
:
Check for virtualenv with no access to global site-packages
stat
:
path
:
'
/var/lib/{{
satnogs_client_user
}}/lib/python2.7/no-global-site-packages.txt'
...
...
@@ -31,7 +36,7 @@
file
:
path
:
'
/var/lib/{{
satnogs_client_user
}}/{{
item
}}'
state
:
'
absent'
when
:
res_no_global.stat.exists and res_no_global.stat.isreg
when
:
(
res_no_global.stat.exists and res_no_global.stat.isreg
) or res_python_version.stdout != ansible_python_version
register
:
res
until
:
res is success
retries
:
3
...
...
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