-
Notifications
You must be signed in to change notification settings - Fork 0
Documentation
The only thing you should really have to change when deploying sink is your config.ini
file. This file is parsed according to PHP's INI File Format.
There are two types of configuration that go into this file:
- Global Config
- Sink Configs
Anything that falls under the [CONFIG]
section heading is considered global config and is available to every sink. In general, output triggers will use this section to store variables. Here is a list of variables that can be placed in this section.
Required
This starts out as CHANGETHISKEY
but you have to change it to make anything work. This will be the same thing you supply as a secret to GitHub when adding the webhook to your account/repository.
Any section heading that is not [CONFIG]
is treated as a sink. A sink represents a connection between a folder on the machine and a branch of a remote GitHub repository. The sink name is whatever you put between the square brackets and can be anything (except CONFIG
obviously) as long as they are unique across the config file.
Here is documentation of the variables which can be placed inside of a sink config.
Required
This should be the account or organization that owns the repository you wish to sync.
Required
This should be the name of the repository you wish to sync.
Optional - defaults to master
The branch of the repository to sync with. The sync commands will only occur when a push event is triggered on this branch.
Required
The directory on the remote machine you wish to sync to the GitHub repository. This can be a relative path (relative to inside the sink
directory) or an absolute path.
Optional - won't reset if not included
You can optionally use this parameter to perform a git reset
on the directory to HEAD
before pulling down changes. The value of the parameter (if included) tells git what reset mode you wish to use when resetting. It should be set to one of the following values:
- hard
- mixed
- soft
- merge
- keep
For example, if RESET_MODE
was set to hard
, the following command would be run before pulling:
git reset --hard HEAD