couchdbcatalog

package
v0.8.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 27, 2017 License: Apache-2.0 Imports: 13 Imported by: 2

README

The FireCamp CouchDB container is based on the apache couchdb image. The data volume will be mounted to the /data directory inside container. The CouchDB data will be stored at the /data/couchdb directory, and the config files are at the /data/conf directory.

Topology

By default, database will have 3 replicas and the replicas will be evenly distributed to the availability zones in the cluster. If the cluster has 3 availability zones, each zone will have one replica. The production cluster should have 3 availability zones, to tolerate the availability zone failure.

Security

The Authentication and Authorization are enabled by default. The admin account is created. The require_valid_user is set to true for both cluster port and node-local port, to reject the requests from the anonymous users. The default admin user is "admin", and password "changeme". You could set the admin user and password to firecamp-service-cli when creating the CouchDB service.

The peruser option is broken in 2.1.0, see CouchDB issue 749. Once CouchDB fixes it, peruser will be supported.

The CouchDB SSL will be supported in the future.

The Cross-Region Resource Sharing (cors) is disabled by default. If you want to enable it, simply set couchdb-enable-cors to true and set credentials, origins, headers and methods when creating the CouchDB service.

The httpd config whitelist is disabled to avoid updating the configuration by mistake via the HTTP API.

Logging

The logs are sent to the Cloud Logs, such as AWS CloudWatch logs.

Documentation

Index

Constants

View Source
const (
	// ContainerImage is the main running container.
	ContainerImage = common.ContainerNamePrefix + "couchdb:" + common.Version
	// InitContainerImage initializes the couchdb cluster.
	InitContainerImage = common.ContainerNamePrefix + "couchdb-init:" + common.Version
)

Variables

This section is empty.

Functions

func GenDefaultCreateServiceRequest

func GenDefaultCreateServiceRequest(platform string, region string, azs []string, cluster string,
	service string, res *common.Resources, opts *manage.CatalogCouchDBOptions) *manage.CreateServiceRequest

GenDefaultCreateServiceRequest returns the default service creation request.

func GenDefaultInitTaskRequest

func GenDefaultInitTaskRequest(req *manage.ServiceCommonRequest, logConfig *cloudlog.LogConfig, azs []string,
	serviceUUID string, replicas int64, manageurl string, admin string, adminPass string) *containersvc.RunTaskOptions

GenDefaultInitTaskRequest returns the default service init task request.

func GenInitTaskEnvKVPairs

func GenInitTaskEnvKVPairs(region string, cluster string, manageurl string, service string,
	azs []string, replicas int64, admin string, adminPass string) []*common.EnvKeyValuePair

GenInitTaskEnvKVPairs generates the environment key-values for the init task.

func GenReplicaConfigs

func GenReplicaConfigs(platform string, cluster string, service string, azs []string, opts *manage.CatalogCouchDBOptions) []*manage.ReplicaConfig

GenReplicaConfigs generates the replica configs.

func ValidateRequest

func ValidateRequest(r *manage.CatalogCreateCouchDBRequest) error

ValidateRequest checks if the request is valid

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL