fix: launch Windows nginx from native project prefix
This commit is contained in:
@@ -40,6 +40,8 @@ jobs:
|
|||||||
- name: Build and verify Aurora Native for Windows
|
- name: Build and verify Aurora Native for Windows
|
||||||
shell: pwsh
|
shell: pwsh
|
||||||
run: |
|
run: |
|
||||||
|
$ErrorActionPreference = 'Stop'
|
||||||
|
$PSNativeCommandUseErrorActionPreference = $true
|
||||||
./runtime-build/windows-x64/stage-runtime.ps1
|
./runtime-build/windows-x64/stage-runtime.ps1
|
||||||
node scripts/smoke-native-runtime.cjs dist/native-runtime-stage/win32-x64
|
node scripts/smoke-native-runtime.cjs dist/native-runtime-stage/win32-x64
|
||||||
$runtime = (Resolve-Path 'dist/native-runtime-stage/win32-x64').Path
|
$runtime = (Resolve-Path 'dist/native-runtime-stage/win32-x64').Path
|
||||||
|
|||||||
Generated
+2
-2
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "aurora-dockside",
|
"name": "aurora-dockside",
|
||||||
"version": "2.0.0-alpha.32",
|
"version": "2.0.0-alpha.33",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "aurora-dockside",
|
"name": "aurora-dockside",
|
||||||
"version": "2.0.0-alpha.32",
|
"version": "2.0.0-alpha.33",
|
||||||
"hasInstallScript": true,
|
"hasInstallScript": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@electron-toolkit/preload": "^3.0.2",
|
"@electron-toolkit/preload": "^3.0.2",
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "aurora-dockside",
|
"name": "aurora-dockside",
|
||||||
"version": "2.0.0-alpha.32",
|
"version": "2.0.0-alpha.33",
|
||||||
"description": "A modern, modular Docker development platform for building, running, and managing web applications locally.",
|
"description": "A modern, modular Docker development platform for building, running, and managing web applications locally.",
|
||||||
"desktopName": "aurora-dockside.desktop",
|
"desktopName": "aurora-dockside.desktop",
|
||||||
"main": "./out/main/index.js",
|
"main": "./out/main/index.js",
|
||||||
|
|||||||
@@ -8,6 +8,7 @@ import { describe, expect, it } from 'vitest'
|
|||||||
import {
|
import {
|
||||||
renderMariaDbConfig,
|
renderMariaDbConfig,
|
||||||
nativeConfigPath,
|
nativeConfigPath,
|
||||||
|
nativeServiceSpecs,
|
||||||
renderNativeAdminerBootstrap,
|
renderNativeAdminerBootstrap,
|
||||||
renderNginxConfig,
|
renderNginxConfig,
|
||||||
renderPhpFpmConfig,
|
renderPhpFpmConfig,
|
||||||
@@ -63,6 +64,17 @@ describe('native project configuration', () => {
|
|||||||
expect(config).toContain('location ~ \\.php$')
|
expect(config).toContain('location ~ \\.php$')
|
||||||
expect(config).toContain(nativeConfigPath(resolve(projectRoot, 'public')))
|
expect(config).toContain(nativeConfigPath(resolve(projectRoot, 'public')))
|
||||||
})
|
})
|
||||||
|
it('launches nginx with a project-relative config path', () => {
|
||||||
|
const web = nativeServiceSpecs({ ...project, installedRuntimeRoot }).find((service) =>
|
||||||
|
service.id.endsWith(':web')
|
||||||
|
)
|
||||||
|
expect(web?.args).toEqual([
|
||||||
|
'-p',
|
||||||
|
`${nativeConfigPath(join(projectRoot, '.aurora', 'native'))}/`,
|
||||||
|
'-c',
|
||||||
|
'config/nginx.conf'
|
||||||
|
])
|
||||||
|
})
|
||||||
it('isolates MariaDB data and networking', () => {
|
it('isolates MariaDB data and networking', () => {
|
||||||
const config = renderMariaDbConfig(project, installedRuntimeRoot)
|
const config = renderMariaDbConfig(project, installedRuntimeRoot)
|
||||||
expect(config).toContain('bind-address=127.0.0.1')
|
expect(config).toContain('bind-address=127.0.0.1')
|
||||||
|
|||||||
@@ -258,10 +258,10 @@ export function nativeServiceSpecs(project: NativeProjectDefinition): NativeServ
|
|||||||
...common('web'),
|
...common('web'),
|
||||||
command: runtimeExecutable(project, 'nginx'),
|
command: runtimeExecutable(project, 'nginx'),
|
||||||
args: [
|
args: [
|
||||||
'-c',
|
|
||||||
nativeConfigPath(join(directory, 'config', 'nginx.conf')),
|
|
||||||
'-p',
|
'-p',
|
||||||
`${nativeConfigPath(directory)}/`
|
`${nativeConfigPath(directory)}/`,
|
||||||
|
'-c',
|
||||||
|
'config/nginx.conf'
|
||||||
],
|
],
|
||||||
ready: { port: project.ports.http }
|
ready: { port: project.ports.http }
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user