-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
1 addition
and
69 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
a# CSlant Home Runner | ||
# CSlant Home Runner | ||
|
||
```text | ||
██╗ ██╗ ██████╗ ███╗ ███╗███████╗ ██████╗ ██╗ ██╗███╗ ██╗███╗ ██╗███████╗██████╗ | ||
|
@@ -66,71 +66,3 @@ The runner has the following commands: | |
| `build`, `b` | Builds the Home | | ||
| `worker`, `w` | Create or restart the worker | | ||
| `all`, `a` | Runs all the commands | | ||
# CSlant Home Runner | ||
|
||
```text | ||
██╗ ██╗ ██████╗ ███╗ ███╗███████╗ ██████╗ ██╗ ██╗███╗ ██╗███╗ ██╗███████╗██████╗ | ||
██║ ██║██╔═══██╗████╗ ████║██╔════╝ ██╔══██╗██║ ██║████╗ ██║████╗ ██║██╔════╝██╔══██╗ | ||
███████║██║ ██║██╔████╔██║█████╗ ██████╔╝██║ ██║██╔██╗ ██║██╔██╗ ██║█████╗ ██████╔╝ | ||
██╔══██║██║ ██║██║╚██╔╝██║██╔══╝ ██╔══██╗██║ ██║██║╚██╗██║██║╚██╗██║██╔══╝ ██╔══██╗ | ||
██║ ██║╚██████╔╝██║ ╚═╝ ██║███████╗ ██║ ██║╚██████╔╝██║ ╚████║██║ ╚████║███████╗██║ ██║ | ||
╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝ ╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═══╝╚═╝ ╚═══╝╚══════╝╚═╝ ╚═╝ | ||
``` | ||
|
||
This repo is to set up the runner for updating homepage at https://cslant.com | ||
|
||
We can use this runner to update the Home automatically with CI/CD pipelines. | ||
|
||
## Installation | ||
|
||
First, copy the `.env.example` file to `.env` and update the values. | ||
|
||
```bash | ||
envsubst < .env.example > .env | ||
``` | ||
|
||
In the `.env` file, update the values to match your environment. | ||
|
||
```bash | ||
# .env | ||
|
||
#SOURCE_DIR=~/source | ||
SOURCE_DIR=/home/user/cslant.com/home | ||
|
||
[email protected]:cslant | ||
|
||
# The name of the runner | ||
WORKER_NAME="CSlant Home" | ||
|
||
# add the env to choose "npm" or "yarn" as the installer | ||
INSTALLER=yarn | ||
|
||
# App Config | ||
# E.g: prod, dev | ||
ENV=prod | ||
|
||
NODE_VERSION=22 | ||
|
||
USE_SUBMODULES=false | ||
``` | ||
|
||
> [!IMPORTANT] | ||
> ## Command can't be used if wrong values are set in the `.env` file. | ||
> * If the `SOURCE_DIR` is wrong, the runner will not be able to find the source code. So, please make sure the `SOURCE_DIR` is correct. | ||
Then, run the following command to start the runner. | ||
|
||
```bash | ||
bash runner.sh all | ||
``` | ||
|
||
## Usage | ||
|
||
The runner has the following commands: | ||
|
||
| Command | Description | | ||
|----------|------------------------------| | ||
| `help` | Shows the help message | | ||
| `build` | Builds the Home | | ||
| `worker` | Create or restart the worker | | ||
| `all` | Runs all the commands | |