Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
php
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
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
webarch
php
Commits
342cb7b6
Commit
342cb7b6
authored
2 years ago
by
Chris Croome
Browse files
Options
Downloads
Patches
Plain Diff
Debug install packages
parent
0289dd6e
No related branches found
No related tags found
1 merge request
!1
Merge Sury
Pipeline
#22506
passed
2 years ago
Stage: lint
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tasks/main.yml
+11
-6
11 additions, 6 deletions
tasks/main.yml
with
11 additions
and
6 deletions
tasks/main.yml
+
11
−
6
View file @
342cb7b6
...
...
@@ -26,19 +26,24 @@
purge
:
true
register
:
php_packages_absent
when
:
-
ansible_local.php.packages.state == "present"
-
ansible_local.php.state == "present"
-
ansible_local.php.packages is defined
-
ansible_local.php.packages | length >
0
-
ansible_local.php.packages | difference(php.packages) | length >
0
-
name
:
Debug the difference between php.packages and ansible_local.php.packages
ansible.builtin.debug
:
msg
:
-
"
{{
php.packages
|
difference(ansible_local.php.packages)
}}"
-
name
:
PHP packages present
ansible.builtin.apt
:
pkg
:
"
{{
php.packages
|
difference(ansible_local.php.packages)
}}"
pkg
:
"
{{
php.packages
}}"
state
:
present
register
:
php_packages_present
when
:
>
( ansible_local.php.state == "absent" or
ansible_local.php.packages.state == "absent" or
php.packages | difference(ansible_local.php.packages) | length > 0 ) and
( php.packages | length > 0 )
( ( ansible_local.php.state == "absent" ) or
( ansible_local.php.packages is defined and php.packages | difference(ansible_local.php.packages) | length > 0 ) )
-
name
:
Re-read Ansible local facts
ansible.builtin.setup
:
...
...
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