Version information
This version is compatible with:
- Puppet Enterprise 2023.2.x, 2023.1.x, 2023.0.x, 2021.7.x, 2021.6.x, 2021.5.x, 2021.4.x, 2021.3.x, 2021.2.x, 2021.1.x, 2021.0.x
- Puppet >= 7.0.0 < 8.0.0
- , ,
Start using this module
Add this module to your Puppetfile:
mod 'anyproto-anysync', '2.0.0'
Learn more about managing modules with a PuppetfileDocumentation
Puppet for any-sync
Table of Contents
- Description
- Setup — The basics of getting started with template
- Usage — Configuration options and additional functionality
- Reference
Description
Module to configure a self-hosted setup for any-sync-* daemons.
Setup
Compatible versions
You can find compatible versions on these pages:
- stable versions, used in production
- unstable versions, used in test stand
Example hiera configuration
---
classes:
- anysync
# enable for relevant group of hosts {{
anysync::consensusnode: true
anysync::coordinator: true
anysync::filenode: true
anysync::node: true
# }}
pkg::any-sync-node: 0.2.12
pkg::any-sync-filenode: 0.3.6
pkg::any-sync-coordinator: 0.2.9
pkg::any-sync-consensusnode: 0.0.4
anysync::filenode::config::cfg:
s3Store:
region: eu-central-1
profile: default
bucket: s3BucketName
maxThreads: 16
redis:
isCluster: true
url: redis://redis1.local:6379?dial_timeout=3&read_timeout=6s&addr=redis1.local:6380&addr=redis3.local:6379&addr=redis3.local:6380&addr=redis2.local:6379&addr=redis2.local:6380
anysync::coordinator::config::cfg:
mongo:
connect: mongodb://coordinator-db1.local:27017,coordinator-db2.local:27017,coordinator-db3.local:27017
fileLimit:
limitDefault: 1073741824
limitAlphaUsers: 10737418240
limitNightlyUsers: 53687091200
anysync::consensusnode::config::cfg:
mongo:
connect: mongodb://coordinator-db1.local:27017,coordinator-db2.local:27017,coordinator-db3.local:27017/?w=majority # "w=majority" is required!
any_sync_accounts:
# tree node {{
node1.local:
peerId: 12D3KooWLTVK3VgXziU8ZcvvHUebueSBPiJNjXBxm3DQWtqsCbWD
peerKey: <secret>
signingKey: <secret>
node2.local:
peerId: 12D3KooWBTWo5KVveQuVEA4VeivgbS7LxGkTgmWspEtpaw3D5xXw
peerKey: <secret>
signingKey: <secret>
node3.local:
peerId: 12D3KooWF8HJnjL8MDUAExyg7yEAXhcXKzMwsn3dvivDjKWe7NN5
peerKey: <secret>
signingKey: <secret>
# }}
# filenode
filenode1.local:
peerId: 12D3KooWJExfEKskv47BP77mrBV2ciCgZgkdZFrL5R1CQjU6DVb6
peerKey: <secret>
signingKey: <secret>
# coordinator
coordinator1.local:
peerId: 12D3KooWRjnz8Ju1hFmY6SzoVYKXBVtqiQXGJkqQesQaRMpF2sVF
peerKey: <secret>
signingKey: <secret> # network signingKey
# consensus
consensusnode1.local:
peerId: 12D3KooWBjCiYhk31PhdjG72M9oQKMbcyC3adsMbT7tMrmTi8KeB
peerKey: <secret>
signingKey: <secret> # network signingKey
anysync::filenode::config::aws_credentials:
default:
aws_access_key_id: <secret>
aws_secret_access_key: <secret>
any_sync_network:
networkId: N5787WrcATL3f9kDUVxz9yeexEoxxmBLQRhJ47SBNBXEhadc
nodes:
- peerId: 12D3KooWLTVK3VgXziU8ZcvvHUebueSBPiJNjXBxm3DQWtqsCbWD
addresses:
- node1.local:443
- quic://node1.local:5430
types: [tree]
- peerId: 12D3KooWBTWo5KVveQuVEA4VeivgbS7LxGkTgmWspEtpaw3D5xXw
addresses:
- node2.local:443
- quic://node2.local:5430
types: [tree]
- peerId: 12D3KooWF8HJnjL8MDUAExyg7yEAXhcXKzMwsn3dvivDjKWe7NN5
addresses:
- node3.local:443
- quic://node3.local:5430
types: [tree]
- peerId: 12D3KooWJExfEKskv47BP77mrBV2ciCgZgkdZFrL5R1CQjU6DVb6
addresses:
- filenode1.local:443
- quic://filenode1.local:5430
types: [file]
- peerId: 12D3KooWRjnz8Ju1hFmY6SzoVYKXBVtqiQXGJkqQesQaRMpF2sVF
addresses:
- coordinator1.local:443
- quic://coordinator1.local:5430
types: [coordinator]
- peerId: 12D3KooWBjCiYhk31PhdjG72M9oQKMbcyC3adsMbT7tMrmTi8KeB
addresses:
- consensusnode1.local:443
- quic://consensusnode1.local:5430
types: [consensus]
Secrets
- To generate keys, please use any-sync-tools
- To encrypt secrets, please use hiera-eyaml
Setup Requirements
- redis
- mongo
Puppet modules requirements
- githubartifact
- puppet-systemd 4.1.0
- optional syslog_ng
- optional consul + tools
- optional collectd
Usage
Apply network config in Mongo
any-sync-confapply -c /etc/any-sync-coordinator/config.yml -n /etc/any-sync-coordinator/network.yml -e
Ahow current config in Mongo
use coordinator
db.nodeConf.find().sort( { _id: -1 } ).limit(1)
Reference
To update REFERENCE.md please run:
puppet strings generate --format markdown
Contribution
Thank you for your desire to develop Anytype together!
❤️ This project and everyone involved in it is governed by the Code of Conduct.
🧑💻 Check out our contributing guide to learn about asking questions, creating issues, or submitting pull requests.
🫢 For security findings, please email security@anytype.io and refer to our security guide for more information.
🤝 Follow us on Github and join the Contributors Community.
Made by Any — a Swiss association 🇨🇭
Licensed under MIT.
Reference
Table of Contents
Classes
anysync
: configures the anysync moduleanysync::consensusnode::config
anysync::consensusnode::install
anysync::consensusnode::monitoring
anysync::consensusnode::service
anysync::coordinator::config
anysync::coordinator::install
anysync::coordinator::monitoring
anysync::coordinator::service
anysync::filenode::config
anysync::filenode::install
anysync::filenode::monitoring
anysync::filenode::service
anysync::node::config
anysync::node::install
anysync::node::monitoring
anysync::node::service
Classes
anysync
configures the anysync module
Parameters
The following parameters are available in the anysync
class:
node
Data type: Boolean
enable or disable "tree node" daemon
filenode
Data type: Boolean
enable or disable "filenode" daemon
coordinator
Data type: Boolean
enable or disable "coordinator" daemon
consensusnode
Data type: Boolean
enable or disable "consensusnode" daemon
syslog_ng
Data type: Boolean
enable or disable syslog-ng configuration for logging
monitoring
Data type: Boolean
enable or disable monitoring manifests
anysync::consensusnode::config
The anysync::consensusnode::config class.
Parameters
The following parameters are available in the anysync::consensusnode::config
class:
cfg
Data type: Hash
Defines config for daemon
accounts
Data type: Hash
Defines "account" settings for all nodes (see "any_sync_accounts" in README.md)
user
Data type: String
Defines user for daemon files and process
group
Data type: String
Defines group for daemon files and process
daemon_name
Data type: String
Defines daemon name
syslog_ng
Data type: Boolean
enable or disable syslog-ng configuration for logging
Default value: $::anysync::syslog_ng
anysync::consensusnode::install
The anysync::consensusnode::install class.
Parameters
The following parameters are available in the anysync::consensusnode::install
class:
githubartifact
Data type: Hash
Defines config for githubartifact
anysync::consensusnode::monitoring
The anysync::consensusnode::monitoring class.
anysync::consensusnode::service
The anysync::consensusnode::service class.
anysync::coordinator::config
The anysync::coordinator::config class.
Parameters
The following parameters are available in the anysync::coordinator::config
class:
cfg
Data type: Hash
Defines config for daemon
accounts
Data type: Hash
Defines "account" settings for all nodes (see "any_sync_accounts" in README.md)
user
Data type: String
Defines user for daemon files and process
group
Data type: String
Defines group for daemon files and process
daemon_name
Data type: String
Defines daemon name
syslog_ng
Data type: Boolean
enable or disable syslog-ng configuration for logging
Default value: $::anysync::syslog_ng
anysync::coordinator::install
The anysync::coordinator::install class.
Parameters
The following parameters are available in the anysync::coordinator::install
class:
githubartifact
Data type: Hash
Defines config for githubartifact
anysync::coordinator::monitoring
The anysync::coordinator::monitoring class.
anysync::coordinator::service
The anysync::coordinator::service class.
anysync::filenode::config
The anysync::filenode::config class.
Parameters
The following parameters are available in the anysync::filenode::config
class:
cfg
Data type: Hash
Defines config for daemon
accounts
Data type: Hash
Defines "account" settings for all nodes (see "any_sync_accounts" in README.md)
user
Data type: String
Defines user for daemon files and process
group
Data type: String
Defines group for daemon files and process
daemon_name
Data type: String
Defines daemon name
aws_credentials
Data type: Hash
Defines credentials for access to s3
syslog_ng
Data type: Boolean
enable or disable syslog-ng configuration for logging
Default value: $::anysync::syslog_ng
anysync::filenode::install
The anysync::filenode::install class.
Parameters
The following parameters are available in the anysync::filenode::install
class:
githubartifact
Data type: Hash
Defines config for githubartifact
anysync::filenode::monitoring
The anysync::filenode::monitoring class.
anysync::filenode::service
The anysync::filenode::service class.
anysync::node::config
The anysync::node::config class.
Parameters
The following parameters are available in the anysync::node::config
class:
cfg
Data type: Hash
Defines config for daemon
accounts
Data type: Hash
Defines "account" settings for all nodes (see "any_sync_accounts" in README.md)
user
Data type: String
Defines user for daemon files and process
group
Data type: String
Defines group for daemon files and process
daemon_name
Data type: String
Defines daemon name
syslog_ng
Data type: Boolean
enable or disable syslog-ng configuration for logging
Default value: $::anysync::syslog_ng
anysync::node::install
The anysync::node::install class.
Parameters
The following parameters are available in the anysync::node::install
class:
githubartifact
Data type: Hash
Defines config for githubartifact
anysync::node::monitoring
The anysync::node::monitoring class.
anysync::node::service
The anysync::node::service class.
Dependencies
- puppetlabs/stdlib (>= 8.5.0)
- puppet/systemd (>= 4.1.0)