Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
A
ansible
Manage
Activity
Members
Labels
Plan
Issues
13
Issue boards
Milestones
Wiki
Code
Merge requests
1
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
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
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
funkwhale
ansible
Commits
2fc665dc
Commit
2fc665dc
authored
1 year ago
by
Georg Krause
Browse files
Options
Downloads
Patches
Plain Diff
fix: Do not try to install certbot if already available
parent
54051738
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#32452
passed with stages
Stage: test
Stage: deploy
in 12 minutes and 43 seconds
Changes
1
Pipelines
45
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tasks/nginx.yml
+10
-5
10 additions, 5 deletions
tasks/nginx.yml
with
10 additions
and
5 deletions
tasks/nginx.yml
+
10
−
5
View file @
2fc665dc
...
...
@@ -15,30 +15,35 @@
# from https://gist.github.com/mattiaslundberg/ba214a35060d3c8603e9b1ec8627d349
-
name
:
Check if certbot is already installed
stat
:
path
:
"
/usr/bin/certbot"
register
:
"
certbot_installed"
-
name
:
Install snapd
when
:
funkwhale_nginx_managed and funkwhale_letsencrypt_enabled
when
:
funkwhale_nginx_managed and funkwhale_letsencrypt_enabled
and not certbot_installed.stat.exists
become
:
true
package
:
name
:
snapd
state
:
present
-
name
:
Prepare snapd for certbot installation
when
:
funkwhale_nginx_managed and funkwhale_letsencrypt_enabled
when
:
funkwhale_nginx_managed and funkwhale_letsencrypt_enabled
and not certbot_installed.stat.exists
become
:
true
command
:
snap install core
-
name
:
Refresh core snap before installing certbot
when
:
funkwhale_nginx_managed and funkwhale_letsencrypt_enabled
when
:
funkwhale_nginx_managed and funkwhale_letsencrypt_enabled
and not certbot_installed.stat.exists
become
:
true
command
:
snap refresh core
-
name
:
Install certbot snap
when
:
funkwhale_nginx_managed and funkwhale_letsencrypt_enabled
when
:
funkwhale_nginx_managed and funkwhale_letsencrypt_enabled
and not certbot_installed.stat.exists
become
:
true
command
:
snap install --classic certbot
-
name
:
Link certbot snap installation
when
:
funkwhale_nginx_managed and funkwhale_letsencrypt_enabled
when
:
funkwhale_nginx_managed and funkwhale_letsencrypt_enabled
and not certbot_installed.stat.exists
become
:
true
file
:
src
:
/snap/bin/certbot
...
...
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