mirror of
https://github.com/SableClient/Sable.git
synced 2026-11-29 13:22:47 -08:00
fix(ci): set working-directory and backend env vars for tofu plan/apply
Signed-off-by: hazre <[email protected]>
This commit is contained in:
1 parent
45c359dea6
commit
8271b82a65
3 files changed
+14
-24
No files matched your search
@@ -74,6 +74,12 @@ jobs:
|
||||
pull-requests: write
|
||||
environment:
|
||||
name: ${{ needs.detect.outputs.environment }}
|
||||
env:
|
||||
TF_HTTP_ADDRESS: ${{ secrets.TF_HTTP_ADDRESS }}
|
||||
TF_HTTP_LOCK_ADDRESS: ${{ secrets.TF_HTTP_LOCK_ADDRESS }}
|
||||
TF_HTTP_UNLOCK_ADDRESS: ${{ secrets.TF_HTTP_UNLOCK_ADDRESS }}
|
||||
TF_VAR_custom_domain: ${{ vars.TF_VAR_CUSTOM_DOMAIN || 'app.sable.moe' }}
|
||||
TF_VAR_worker_name: ${{ vars.TF_VAR_WORKER_NAME || 'sable' }}
|
||||
steps:
|
||||
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
||||
with:
|
||||
@@ -84,11 +90,6 @@ jobs:
|
||||
with:
|
||||
build-flavor: ${{ needs.detect.outputs.build_flavor }}
|
||||
env:
|
||||
TF_HTTP_ADDRESS: ${{ secrets.TF_HTTP_ADDRESS }}
|
||||
TF_HTTP_LOCK_ADDRESS: ${{ secrets.TF_HTTP_LOCK_ADDRESS }}
|
||||
TF_HTTP_UNLOCK_ADDRESS: ${{ secrets.TF_HTTP_UNLOCK_ADDRESS }}
|
||||
TF_VAR_custom_domain: ${{ vars.TF_VAR_CUSTOM_DOMAIN || 'app.sable.moe' }}
|
||||
TF_VAR_worker_name: ${{ vars.TF_VAR_WORKER_NAME || 'sable' }}
|
||||
VITE_SENTRY_DSN: ${{ secrets.VITE_SENTRY_DSN }}
|
||||
VITE_SENTRY_ENVIRONMENT: ${{ needs.detect.outputs.sentry_environment }}
|
||||
VITE_APP_VERSION: ${{ needs.detect.outputs.version }}
|
||||
@@ -97,6 +98,7 @@ jobs:
|
||||
SENTRY_PROJECT: ${{ secrets.SENTRY_PROJECT }}
|
||||
|
||||
- name: Plan infrastructure
|
||||
working-directory: infra/web
|
||||
run: mise run opentofu -- plan -input=false -no-color
|
||||
|
||||
- name: Comment PR plan
|
||||
@@ -115,6 +117,12 @@ jobs:
|
||||
environment:
|
||||
name: ${{ needs.detect.outputs.environment }}
|
||||
url: https://${{ vars.TF_VAR_CUSTOM_DOMAIN || 'app.sable.moe' }}
|
||||
env:
|
||||
TF_HTTP_ADDRESS: ${{ secrets.TF_HTTP_ADDRESS }}
|
||||
TF_HTTP_LOCK_ADDRESS: ${{ secrets.TF_HTTP_LOCK_ADDRESS }}
|
||||
TF_HTTP_UNLOCK_ADDRESS: ${{ secrets.TF_HTTP_UNLOCK_ADDRESS }}
|
||||
TF_VAR_custom_domain: ${{ vars.TF_VAR_CUSTOM_DOMAIN || 'app.sable.moe' }}
|
||||
TF_VAR_worker_name: ${{ vars.TF_VAR_WORKER_NAME || 'sable' }}
|
||||
concurrency:
|
||||
group: cloudflare-infra-${{ needs.detect.outputs.environment }}
|
||||
cancel-in-progress: false
|
||||
@@ -128,11 +136,6 @@ jobs:
|
||||
with:
|
||||
build-flavor: ${{ needs.detect.outputs.build_flavor }}
|
||||
env:
|
||||
TF_HTTP_ADDRESS: ${{ secrets.TF_HTTP_ADDRESS }}
|
||||
TF_HTTP_LOCK_ADDRESS: ${{ secrets.TF_HTTP_LOCK_ADDRESS }}
|
||||
TF_HTTP_UNLOCK_ADDRESS: ${{ secrets.TF_HTTP_UNLOCK_ADDRESS }}
|
||||
TF_VAR_custom_domain: ${{ vars.TF_VAR_CUSTOM_DOMAIN || 'app.sable.moe' }}
|
||||
TF_VAR_worker_name: ${{ vars.TF_VAR_WORKER_NAME || 'sable' }}
|
||||
VITE_SENTRY_DSN: ${{ secrets.VITE_SENTRY_DSN }}
|
||||
VITE_SENTRY_ENVIRONMENT: ${{ needs.detect.outputs.sentry_environment }}
|
||||
VITE_APP_VERSION: ${{ needs.detect.outputs.version }}
|
||||
@@ -141,4 +144,5 @@ jobs:
|
||||
SENTRY_PROJECT: ${{ secrets.SENTRY_PROJECT }}
|
||||
|
||||
- name: Apply infrastructure
|
||||
working-directory: infra/web
|
||||
run: mise run opentofu -- apply -input=false -auto-approve
|
||||
@@ -54,10 +54,6 @@ export async function saveDownload(params: types.SaveDownloadParams): Promise<bo
|
||||
return invoke('save_download', params);
|
||||
}
|
||||
|
||||
export async function setMediaEncryption(params: types.SetMediaEncryptionParams): Promise<void> {
|
||||
return invoke('set_media_encryption', params);
|
||||
}
|
||||
|
||||
export async function setMediaSession(params: types.SetMediaSessionParams): Promise<void> {
|
||||
return invoke('set_media_session', params);
|
||||
}
|
||||
|
||||
@@ -103,16 +103,6 @@ export interface SaveDownloadParams {
|
||||
[key: string]: unknown;
|
||||
}
|
||||
|
||||
export interface SetMediaEncryptionParams {
|
||||
url: string;
|
||||
key: string;
|
||||
iv: string;
|
||||
sha256: string;
|
||||
version: string;
|
||||
mimeType: string;
|
||||
[key: string]: unknown;
|
||||
}
|
||||
|
||||
export interface SetMediaSessionParams {
|
||||
baseUrl: string;
|
||||
token: string;
|
||||
|
||||
Reference in new issue
Block a user