mirror of
https://github.com/Expand-sys/DEPLOYCCASH
synced 2026-03-22 09:47:09 +11:00
Update README.md
This commit is contained in:
parent
bbe9872f6d
commit
3834076bbd
1 changed files with 4 additions and 25 deletions
29
README.md
29
README.md
|
|
@ -7,30 +7,9 @@ As CCash is intended to be run as root, the playbook is run also as root. The pl
|
|||
|
||||
In order to use the ansible playbook, clone the playbook to any pc with the ability to access the server through SSH and with Ansible installed, edit the inventory file to contain the IP address of the target server and run the following commands:
|
||||
|
||||
```ansible-playbook -i deployment/inventory deployment/main.yml -k```
|
||||
```ansible-playbook -i inventory main.ansible.yml -k```
|
||||
When this is complete the server will have ccash installed to the user dir, this is customizable in the vars/default.yml file along with the admin username and save frequency.
|
||||
To start CCash run:
|
||||
```systemctl start ccash```
|
||||
To run ccash at start up run:
|
||||
```systemctl enable ccash```
|
||||
|
||||
## Build
|
||||
Previously this used GitHub Workflows, I(Expand) dont know how to do those but its not that hard to deploy stuff manually. To run the pre configured docker image run the above command and you are off to the races it will deploy a self signed certificate and use that for deployment. As this is not a user facing deployment the certificate is self signed and thus will throw an error on chrome, though this will still work if you ignore it. For production you should deploy with a reverse proxy and a correct certificate for your domain.
|
||||
|
||||
To build this manually you may download the dockerfile only, it will pull the latest repository the commands for building are
|
||||
|
||||
docker build --build-arg ADMIN_A= --build-arg SAVE_FREQ= -t ccash . --no-cache docker run -itp 443:443 -v ccashconfig:/ccash/config -e ADMIN_A= -e SAVE_FREQ= ccash
|
||||
|
||||
if you have the know how you may edit the docker file and add CMAKE commands as listed in the build section of the CCash documentation.
|
||||
|
||||
## Deploy
|
||||
|
||||
You can deploy this docker image to be run on a remote machine in a few steps or you can deploy manually in this case we are using [Debian OS](https://www.debian.org/) running on the [Linode](https://www.linode.com/) cloud provider, but most OS and cloud providers will work, assuming the machine can run an SSH server.
|
||||
|
||||
Additionally, there is a dockerfile where you can build it yourself or a repository available on [dockerhub](https://hub.docker.com/r/expandsys/ccash) for you to just pull and run on any machine quickly and easily.
|
||||
|
||||
### Configure the machine
|
||||
For docker deployment there is one supported config and that is the command listed above,
|
||||
ADMIN_A = Admin account name, must be all lowercase, and the account must be created before use. To do this either use the [CCashDeploy](https://hub.docker.com/r/expandsys/ccashdeploy) docker image and use the CCashFrontend to register the account or use curl to send the raw command to the endpoint.
|
||||
SAVE_FREQ = Saving frequency in minutes, pretty simple
|
||||
To start CCash you can CD into the directory CCash is installed then run ./build/bank {ADMIN ACCOUNT} {SAVE FREQUENCY} true
|
||||
replacing {ADMIN ACCOUNT} with your admin account username and {SAVE FREQUENCY} with the amount of minutes you want to wait for the bank to autosave.
|
||||
true just means that the server will be run in daemon mode and will run as a background process
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue