mirror of
https://github.com/goreleaser/goreleaser.git
synced 2025-01-06 03:13:48 +02:00
docs: add nexus example
closes #1549 Signed-off-by: Carlos Alexandro Becker <caarlos0@gmail.com>
This commit is contained in:
parent
28230b67f8
commit
a92774f602
@ -108,3 +108,24 @@ which may require non-trivial authentication or has otherwise complex requiremen
|
||||
|
||||
!!! tip
|
||||
Learn more about the [name template engine](/customization/templates).
|
||||
|
||||
## Examples
|
||||
|
||||
### Publish to Nexus
|
||||
|
||||
Example of a `publishers` section pushing files to a Nexus instance:
|
||||
|
||||
```yaml
|
||||
publishers:
|
||||
- name: nexus
|
||||
cmd: >-
|
||||
curl -k -u "{{ .Env.NEXUS_USERNAME }}:{{ .Env.NEXUS_PASSWORD }}"
|
||||
-X POST
|
||||
-H "Accept: application/json"
|
||||
-H "Content-Type: multipart/form-data"
|
||||
"https://nexuspro.somehost.com/service/rest/v1/components?repository=go-raw-autopub"
|
||||
-F "raw.directory={{ tolower .Env.PROJECT_KEY }}/{{ tolower .ProjectName }}/{{ .Version }}"
|
||||
-F "raw.asset1=@{{ .ArtifactName }};type=application/gzip"
|
||||
-F "raw.asset1.filename={{ .ArtifactName }}"
|
||||
dir: "{{ dir .ArtifactPath }}"
|
||||
```
|
||||
|
Loading…
Reference in New Issue
Block a user