Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
configuration
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
configuration
Commits
347c7b21
Commit
347c7b21
authored
Jul 19, 2016
by
Brian Beggs
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add tags to password restore tasks
parent
3e010c2d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
5 deletions
+15
-5
playbooks/roles/go-server/tasks/main.yml
+15
-5
No files found.
playbooks/roles/go-server/tasks/main.yml
View file @
347c7b21
...
@@ -80,18 +80,24 @@
...
@@ -80,18 +80,24 @@
/usr/bin/htpasswd -nbs "{{ GO_SERVER_ADMIN_USERNAME }}" "{{ GO_SERVER_ADMIN_PASSWORD }}"
/usr/bin/htpasswd -nbs "{{ GO_SERVER_ADMIN_USERNAME }}" "{{ GO_SERVER_ADMIN_PASSWORD }}"
register
:
admin_user_password_line
register
:
admin_user_password_line
when
:
GO_SERVER_ADMIN_USERNAME and GO_SERVER_ADMIN_PASSWORD
when
:
GO_SERVER_ADMIN_USERNAME and GO_SERVER_ADMIN_PASSWORD
tags
:
-
local_password
-
name
:
generate line for go-server password file for backup user
-
name
:
generate line for go-server password file for backup user
command
:
>
command
:
>
/usr/bin/htpasswd -nbs "{{ GO_SERVER_BACKUP_USERNAME }}" "{{ GO_SERVER_BACKUP_PASSWORD }}"
/usr/bin/htpasswd -nbs "{{ GO_SERVER_BACKUP_USERNAME }}" "{{ GO_SERVER_BACKUP_PASSWORD }}"
register
:
backup_user_password_line
register
:
backup_user_password_line
when
:
GO_SERVER_BACKUP_USERNAME and GO_SERVER_BACKUP_PASSWORD
when
:
GO_SERVER_BACKUP_USERNAME and GO_SERVER_BACKUP_PASSWORD
tags
:
-
local_password
-
name
:
generate line for go-server password file for gomatic user
-
name
:
generate line for go-server password file for gomatic user
command
:
>
command
:
>
/usr/bin/htpasswd -nbs "{{ GO_SERVER_GOMATIC_USERNAME }}" "{{ GO_SERVER_GOMATIC_PASSWORD }}"
/usr/bin/htpasswd -nbs "{{ GO_SERVER_GOMATIC_USERNAME }}" "{{ GO_SERVER_GOMATIC_PASSWORD }}"
register
:
gomatic_user_password_line
register
:
gomatic_user_password_line
when
:
GO_SERVER_GOMATIC_USERNAME and GO_SERVER_GOMATIC_PASSWORD
when
:
GO_SERVER_GOMATIC_USERNAME and GO_SERVER_GOMATIC_PASSWORD
tags
:
-
local_password
-
name
:
setup password file
-
name
:
setup password file
template
:
template
:
...
@@ -101,7 +107,9 @@
...
@@ -101,7 +107,9 @@
owner
:
"
{{
GO_SERVER_USER
}}"
owner
:
"
{{
GO_SERVER_USER
}}"
group
:
"
{{
GO_SERVER_GROUP
}}"
group
:
"
{{
GO_SERVER_GROUP
}}"
force
:
no
force
:
no
when
:
GO_SERVER_ADMIN_PASSWORD and GO_SERVER_BACKUP_PASSWORD AND GO_SERVER_GOMATIC_PASSWORD
when
:
GO_SERVER_ADMIN_PASSWORD and GO_SERVER_BACKUP_PASSWORD and GO_SERVER_GOMATIC_PASSWORD
tags
:
-
local_password
-
name
:
install go-server configuration
-
name
:
install go-server configuration
template
:
template
:
...
@@ -119,12 +127,14 @@
...
@@ -119,12 +127,14 @@
lineinfile
:
lineinfile
:
dest
:
"
{{
GO_SERVER_CONF_HOME
}}/{{
GO_SERVER_PASSWORD_FILE_NAME
}}"
dest
:
"
{{
GO_SERVER_CONF_HOME
}}/{{
GO_SERVER_PASSWORD_FILE_NAME
}}"
regexp
:
"
^{{
item.username
}}"
regexp
:
"
^{{
item.username
}}"
line
:
"
{{
item.password_hash
.stdout
}}"
line
:
"
{{
item.password_hash
}}"
with_items
:
with_items
:
-
{
username
:
GO_SERVER_ADMIN_USERNAME
,
password
:
GO_SERVER_ADMIN_PASSWORD
,
password_hash
:
admin_user_password_line
}
-
{
username
:
"
{{
GO_SERVER_ADMIN_USERNAME
}}"
,
password
:
"
{{
GO_SERVER_ADMIN_PASSWORD
}}"
,
password_hash
:
"
{{
admin_user_password_line.stdout
}}"
}
-
{
username
:
GO_SERVER_BACKUP_USERNAME
,
password
:
GO_SERVER_BACKUP_PASSWORD
,
password_hash
:
backup_user_password_line
}
-
{
username
:
"
{{
GO_SERVER_BACKUP_USERNAME
}}"
,
password
:
"
{{
GO_SERVER_BACKUP_PASSWORD
}}"
,
password_hash
:
"
{{
backup_user_password_line.stdout
}}"
}
-
{
username
:
GO_SERVER_GOMATIC_USERNAME
,
password
:
GO_SERVER_GOMATIC_PASSWORD
,
password_hash
:
gomatic_user_password_line
}
-
{
username
:
"
{{
GO_SERVER_GOMATIC_USERNAME
}}"
,
password
:
"
{{
GO_SERVER_GOMATIC_PASSWORD
}}"
,
password_hash
:
"
{{
gomatic_user_password_line.stdout
}}"
}
when
:
item.username and item.password and item.password_hash
when
:
item.username and item.password and item.password_hash
tags
:
-
local_password
-
name
:
restart go-server
-
name
:
restart go-server
service
:
service
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment