Skip to content

Commit

Permalink
Update documentation for issue voxpupuli#151 workaround and give bett…
Browse files Browse the repository at this point in the history
…er local file usage example
  • Loading branch information
Jonathan Gray committed May 12, 2016
1 parent 58de775 commit 92dcead
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
3. [Setup](#setup)
4. [Usage](#usage)
* [Example](#usage-example)
* [Puppet URL](#puppet-url)
* [File permission](#file-permission)
* [Network files](#network-files)
* [Extract customization](#extract-customization)
Expand Down Expand Up @@ -131,6 +132,29 @@ archive { '/tmp/test100k.db':
}
```

### Puppet URL

Currently there isn't support for using ```puppet:\\``` style url in the source parameter. It is still possible, but it would be done in two steps:

```puppet
$docs_filename = 'help.tar.gz'
$docs_gz_path = "/tmp/${docs_filename}"
$homedir = '/home/myuser/'
file {$docs_gz_path:
ensure => file,
source => "puppet:///modules/profile/${docs_filename}",
}
archive { $docs_gz_path:
path => $docs_gz_path,
extract => true,
extract_path => $homedir,
creates => "${homedir}/help" #directory inside tgz
require => [ File[$homedir], File[$docs_gz_path] ],
}
```

### File permission

When extracting files as non-root user, either ensure the target directory
Expand Down

0 comments on commit 92dcead

Please sign in to comment.