Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
hello-nginx-from-ICG
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
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
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
PIACERE
public
demos
hello-nginx-from-ICG
Commits
96151394
You need to sign in or sign up before continuing.
Commit
96151394
authored
2 years ago
by
debora.benedetto@hpe.com
Browse files
Options
Downloads
Patches
Plain Diff
Upload New File
parent
ac8fd0a2
No related branches found
Branches containing commit
Tags
6.0
6.0.0
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
nginx.play
+45
-0
45 additions, 0 deletions
nginx.play
with
45 additions
and
0 deletions
nginx.play
0 → 100644
+
45
−
0
View file @
96151394
---
- hosts: 16.0.0.1
gather_facts: no
become: yes
vars:
ansible_ssh_private_key_file: "/home/user1/.ssh/openstack.key"
ansible_ssh_user: "ubuntu"
tasks:
- name: Update repositories
apt:
update_cache: yes
- name: Install nginx
package:
name: nginx
- name: Start nginx
service:
name: nginx
enabled: yes
state: started
- name: Set attributes
set_stats:
data:
site_config_dir: /etc/nginx/conf.d
- name: Install sample site
copy:
dest: ""
content: |
<!doctype html>
<html
lang=
"en"
>
<head>
<title>
Hello World!
</title>
</head>
<body>
<h1>
Sample web page
</h1>
<p>
With little content ;)
</p>
</body>
</html>
with_items:
- /var/www/html/index.html
- /usr/share/nginx/html/index.html
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