Skip to content

Commit e22556d

Browse files
committed
Sleep if no app_key set. Add dummy app_key to CI
1 parent 9df787b commit e22556d

File tree

5 files changed

+9
-7
lines changed

5 files changed

+9
-7
lines changed

Jenkinsfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ pipeline {
3434
CI_PORT='80'
3535
CI_SSL='false'
3636
CI_DELAY='60'
37-
CI_DOCKERENV=''
37+
CI_DOCKERENV='APP_KEY=base64:w4fvYUSRozulci8bYVk9wCaRVge3PMF7ixo9fDz9T7o='
3838
CI_AUTH=''
3939
CI_WEBPATH=''
4040
}

README.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -77,8 +77,8 @@ services:
7777
- PUID=1000
7878
- PGID=1000
7979
- TZ=Etc/UTC
80+
- APP_KEY=
8081
- DB_CONNECTION=sqlite
81-
- APP_KEY= #optional
8282
- DB_HOST= #optional
8383
- DB_PORT= #optional
8484
- DB_DATABASE= #optional
@@ -99,8 +99,8 @@ docker run -d \
9999
-e PUID=1000 \
100100
-e PGID=1000 \
101101
-e TZ=Etc/UTC \
102+
-e APP_KEY= \
102103
-e DB_CONNECTION=sqlite \
103-
-e APP_KEY= `#optional` \
104104
-e DB_HOST= `#optional` \
105105
-e DB_PORT= `#optional` \
106106
-e DB_DATABASE= `#optional` \
@@ -122,8 +122,8 @@ Containers are configured using parameters passed at runtime (such as those abov
122122
| `-e PUID=1000` | for UserID - see below for explanation |
123123
| `-e PGID=1000` | for GroupID - see below for explanation |
124124
| `-e TZ=Etc/UTC` | specify a timezone to use, see this [list](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List). |
125+
| `-e APP_KEY=` | App key used for encrypting stored data. You can generate a key at [https://speedtest-tracker.dev](https://speedtest-tracker.dev) |
125126
| `-e DB_CONNECTION=sqlite` | Set the database type to use. `sqlite`, `pgsql`, or `mysql` |
126-
| `-e APP_KEY=` | App key used for encrypting stored data. Generate with `docker exec speedtest-tracker php /app/www/artisan key:generate --show` |
127127
| `-e DB_HOST=` | Database hostname (postgres/mysql). |
128128
| `-e DB_PORT=` | Database port (postgres/mysql). |
129129
| `-e DB_DATABASE=` | Database name (postgres/mysql). |
@@ -292,6 +292,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64
292292

293293
## Versions
294294

295+
* **07.06.24:** - Cache Filament components and added APP_KEY as a required param.
295296
* **27.05.24:** - Existing users should update their nginx confs to avoid http2 deprecation warnings.
296297
* **24.05.24:** - Rebase to Alpine 3.20.
297298
* **16.04.24:** - Rebase to Alpine 3.19, upgrade to php 8.3.

jenkins-vars.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ repo_vars:
2424
- CI_PORT='80'
2525
- CI_SSL='false'
2626
- CI_DELAY='60'
27-
- CI_DOCKERENV=''
27+
- CI_DOCKERENV='APP_KEY=base64:w4fvYUSRozulci8bYVk9wCaRVge3PMF7ixo9fDz9T7o='
2828
- CI_AUTH=''
2929
- CI_WEBPATH=''
3030
sponsor_links:

readme-vars.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ common_param_env_vars_enabled: true
2020
param_container_name: "{{ project_name }}"
2121
param_usage_include_env: true
2222
param_env_vars:
23-
- { env_var: "APP_KEY", env_value: "", desc: "App key used for encrypting stored data. You can generate a key at https://speedtest-tracker.dev" }
23+
- { env_var: "APP_KEY", env_value: "", desc: "App key used for encrypting stored data. You can generate a key at [https://speedtest-tracker.dev](https://speedtest-tracker.dev)" }
2424
- { env_var: "DB_CONNECTION", env_value: "sqlite", desc: "Set the database type to use. `sqlite`, `pgsql`, or `mysql`" }
2525
param_usage_include_vols: true
2626
param_volumes:

root/etc/s6-overlay/s6-rc.d/init-speedtest-tracker-config/run

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,9 @@ fi
8383
# Check for app key
8484
if [[ -z ${APP_KEY} ]]; then
8585
if ! grep -qE "APP_KEY=[0-9A-Za-z:+\/=]{1,}" /app/www/.env 2> /dev/null; then
86-
echo "An application key is missing!"
86+
echo "An application key is missing, halting init!"
8787
echo "You can generate a key at https://speedtest-tracker.dev/."
88+
sleep infinity
8889
fi
8990
fi
9091

0 commit comments

Comments
 (0)