Cortex-Analyzers/.drone.yml
2020-06-30 11:29:30 +02:00

138 lines
3.3 KiB
YAML

---
kind: pipeline
name: default
steps:
- name: build analyzers for release
image: thehiveproject/cortex-worker-builder
settings:
worker_path: analyzers
namespace: cortexneurons
user: {from_secret: docker_username}
password: {from_secret: docker_password}
stable: true
when:
event: [tag]
- name: build responders for release
image: thehiveproject/cortex-worker-builder
settings:
worker_path: responders
namespace: cortexneurons
user: {from_secret: docker_username}
password: {from_secret: docker_password}
stable: true
when:
event: [tag]
- name: build snapshot analyzers
image: thehiveproject/cortex-worker-builder
settings:
worker_path: analyzers
namespace: cortexneurons
user: {from_secret: docker_username}
password: {from_secret: docker_password}
when:
branch:
- develop
event: {exclude: [tag]}
- name: build snapshot responders
image: thehiveproject/cortex-worker-builder
settings:
worker_path: responders
namespace: cortexneurons
user: {from_secret: docker_username}
password: {from_secret: docker_password}
when:
branch:
- develop
event: {exclude: [tag]}
- name: build catalogs
image: thehiveproject/neurons-build-catalogs
when:
branch:
- develop
- master
- name: upload catalogs to bintray
image: thehiveproject/drone-bintray
settings:
user: {from_secret: bintray_user}
key: {from_secret: bintray_key}
subject: thehive-project
package: catalogs
version: latest
override: 1
publish: 1
commands:
- |
export PLUGIN_USER
export PLUGIN_KEY
export PLUGIN_SUBJECT
export PLUGIN_PACKAGE
export PLUGIN_VERSION
export PLUGIN_OVERRIDE
export PLUGIN_PUBLISH
upload \
--file analyzers/analyzers.json \
--repo cortexneurons
upload \
--file analyzers/analyzers-stable.json \
--repo cortexneurons
upload \
--file responders/responders.json \
--repo cortexneurons
upload \
--file responders/responders-stable.json \
--repo cortexneurons
when:
event: [tag]
- name: upload devel catalogs to bintray
image: thehiveproject/drone-bintray
settings:
user: {from_secret: bintray_user}
key: {from_secret: bintray_key}
subject: thehive-project
package: catalogs
version: latest
override: 1
publish: 1
commands:
- |
export PLUGIN_USER
export PLUGIN_KEY
export PLUGIN_SUBJECT
export PLUGIN_PACKAGE
export PLUGIN_VERSION
export PLUGIN_OVERRIDE
export PLUGIN_PUBLISH
upload \
--file analyzers/analyzers-devel.json \
--repo cortexneurons
upload \
--file responders/responders-devel.json \
--repo cortexneurons
when:
branch:
- develop
- name: Prepare documentation files
image: thehiveproject/doc-builder
settings:
type: Cortex-Neurons
when:
branch:
- release/2.8.0
- name: Publish documentation
image: thehiveproject/mkdocs
settings:
token: { from_secret: github_token }
when:
branch:
- release/2.8.0