https://github.com/banool/team_heist_tactics
Weeeeeee!!!!!!!!!!!!!!
https://github.com/banool/team_heist_tactics
Last synced: 11 months ago
JSON representation
Weeeeeee!!!!!!!!!!!!!!
- Host: GitHub
- URL: https://github.com/banool/team_heist_tactics
- Owner: banool
- Created: 2020-06-11T16:01:12.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2023-03-06T07:57:24.000Z (over 3 years ago)
- Last Synced: 2024-03-18T04:35:09.891Z (about 2 years ago)
- Language: Rust
- Homepage: https://heist.team
- Size: 13.6 MB
- Stars: 3
- Watchers: 3
- Forks: 3
- Open Issues: 40
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Team Heist Tactics
[](https://github.com/banool/team_heist_tactics/actions)
Yayyy!!!!!!!!
For UI specific stuff see ui/
## Developing
Before anything, install the pre-commit hook:
```
cd .git/hooks
ln -s ../../other/pre-commit
```
This makes sure that you format your code before you commit.
First, make sure you have all this stuff:
- Node (>= v16, use nvm to help with this)
- Yarn (https://classic.yarnpkg.com/en/docs/install/)
- Cargo (https://rustup.rs/)
- Rust >=1.53
- Protoc (http://google.github.io/proto-lens/installing-protoc.html)
Getting all the JS dependencies:
```
cd ui
yarn install
```
Building the UI, generating protobuf types, building the server, and then running it:
```
./run.sh
```
Linting:
```
rg --files | grep '\.rs' | xargs rustfmt --edition 2018
```
**Note**: If you're not using run.sh, make sure to generate the types yourself with `ui/generate_types.sh`, I don't check them in.
## Deploying
Build container:
```
docker build . -t team_heist_tactics
```
Run container:
```
docker run -p 19996:19996 -it team_heist_tactics:latest
```
Note: Running it won't work locally on its own unless you set `THT_DEPLOYMENT_MODE` to `dev` in the Dockerfile.
## Properly deploying
Use https://github.com/banool/server-setup with something like this:
```
ansible-playbook -i hosts_external everything.yaml --extra-vars "@vars.json" --tags base,tht,https,nginx
```
This setup binds a static directory into the container from the host. When the container starts, it copies the static content in to it. Nginx on the host serves the content in there itself.
## Other
I use git lfs to manage the static content right here in the repo instead of using some other static content hosting thingo.