Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
18
Merge Requests
18
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
nexedi
slapos.core
Commits
b681d30c
Commit
b681d30c
authored
May 16, 2014
by
Marco Mariani
Committed by
Rafael Monnerat
Nov 10, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cli: added missing O_TRUNC to os.open
parent
96a702cc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
slapos/cli/configure_client.py
slapos/cli/configure_client.py
+3
-3
No files found.
slapos/cli/configure_client.py
View file @
b681d30c
...
@@ -108,15 +108,15 @@ def do_configure_client(logger, master_url_web, token, config_path, master_url):
...
@@ -108,15 +108,15 @@ def do_configure_client(logger, master_url_web, token, config_path, master_url):
# write everything
# write everything
with
os
.
fdopen
(
os
.
open
(
config_path
,
os
.
O_CREAT
|
os
.
O_WRONLY
,
0o600
),
'w'
)
as
fout
:
with
os
.
fdopen
(
os
.
open
(
config_path
,
os
.
O_CREAT
|
os
.
O_
TRUNC
|
os
.
O_
WRONLY
,
0o600
),
'w'
)
as
fout
:
logger
.
debug
(
'Writing configuration to %s'
,
config_path
)
logger
.
debug
(
'Writing configuration to %s'
,
config_path
)
fout
.
write
(
cfg
)
fout
.
write
(
cfg
)
with
os
.
fdopen
(
os
.
open
(
cert_path
,
os
.
O_CREAT
|
os
.
O_WRONLY
,
0o600
),
'w'
)
as
fout
:
with
os
.
fdopen
(
os
.
open
(
cert_path
,
os
.
O_CREAT
|
os
.
O_
TRUNC
|
os
.
O_
WRONLY
,
0o600
),
'w'
)
as
fout
:
logger
.
debug
(
'Writing certificate to %s'
,
cert_path
)
logger
.
debug
(
'Writing certificate to %s'
,
cert_path
)
fout
.
write
(
certificate
)
fout
.
write
(
certificate
)
with
os
.
fdopen
(
os
.
open
(
key_path
,
os
.
O_CREAT
|
os
.
O_WRONLY
,
0o600
),
'w'
)
as
fout
:
with
os
.
fdopen
(
os
.
open
(
key_path
,
os
.
O_CREAT
|
os
.
O_
TRUNC
|
os
.
O_
WRONLY
,
0o600
),
'w'
)
as
fout
:
logger
.
debug
(
'Writing key to %s'
,
key_path
)
logger
.
debug
(
'Writing key to %s'
,
key_path
)
fout
.
write
(
key
)
fout
.
write
(
key
)
...
...
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