mirror of
https://github.com/collinbarrett/FilterLists.git
synced 2026-03-11 09:04:27 +00:00
build: 🔨🚧 WIP enabling dev hot reload for web
This commit is contained in:
parent
6ce7addb77
commit
e1e85b754f
8 changed files with 35 additions and 18 deletions
|
|
@ -4,13 +4,21 @@ version: "3.8"
|
|||
|
||||
services:
|
||||
reverse_proxy:
|
||||
image: nginx:alpine
|
||||
ports:
|
||||
- "80:80"
|
||||
volumes:
|
||||
- ./reverse-proxy/conf.d.dev:/etc/nginx/conf.d:ro
|
||||
command: ["nginx-debug", "-g", "daemon off;"]
|
||||
|
||||
web:
|
||||
build:
|
||||
dockerfile: debug.Dockerfile
|
||||
volumes:
|
||||
- .:/app
|
||||
- /app/node_modules
|
||||
environment:
|
||||
- CHOKIDAR_USEPOLLING=true
|
||||
|
||||
directory.api:
|
||||
build:
|
||||
dockerfile: directory/src/FilterLists.Directory.Api/debug.Dockerfile
|
||||
|
|
@ -19,4 +27,4 @@ services:
|
|||
- ASPNETCORE_URLS=http://+:80
|
||||
|
||||
directory.db:
|
||||
command: ["postgres", "-c", "log_statement=all"]
|
||||
command: ["postgres", "-c", "log_statement=all"]
|
||||
|
|
|
|||
|
|
@ -4,9 +4,8 @@ version: "3.8"
|
|||
|
||||
services:
|
||||
reverse_proxy:
|
||||
image: nginx:alpine
|
||||
ports:
|
||||
- "443:443"
|
||||
volumes:
|
||||
- ./reverse-proxy/conf.d:/etc/nginx/conf.d:ro
|
||||
- ~/cert:/etc/nginx/cert:ro
|
||||
- ~/cert:/etc/nginx/cert:ro
|
||||
|
|
|
|||
|
|
@ -49,4 +49,4 @@ networks:
|
|||
directory:
|
||||
|
||||
volumes:
|
||||
directory.db:
|
||||
directory.db:
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ server {
|
|||
}
|
||||
|
||||
location / {
|
||||
proxy_pass http://web:80;
|
||||
proxy_pass http://web:3000;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection keep-alive;
|
||||
|
|
|
|||
|
|
@ -1,7 +1,4 @@
|
|||
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:s="clr-namespace:System;assembly=mscorlib"
|
||||
xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml"
|
||||
xmlns:wpf="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
|
||||
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml" xmlns:wpf="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
|
||||
<s:String x:Key="/Default/CodeStyle/CodeCleanup/Profiles/=FilterLists_0020Cleanup/@EntryIndexedValue"><?xml version="1.0" encoding="utf-16"?><Profile name="FilterLists Cleanup"><CSReorderTypeMembers>True</CSReorderTypeMembers><XMLReformatCode>True</XMLReformatCode><CSCodeStyleAttributes ArrangeTypeAccessModifier="True" ArrangeTypeMemberAccessModifier="True" SortModifiers="True" RemoveRedundantParentheses="True" AddMissingParentheses="True" ArrangeBraces="True" ArrangeAttributes="True" ArrangeArgumentsStyle="True" ArrangeCodeBodyStyle="True" ArrangeVarStyle="True" ArrangeTrailingCommas="True" /><RemoveCodeRedundanciesVB>True</RemoveCodeRedundanciesVB><Xaml.RedundantFreezeAttribute>True</Xaml.RedundantFreezeAttribute><Xaml.RemoveRedundantModifiersAttribute>True</Xaml.RemoveRedundantModifiersAttribute><Xaml.RemoveRedundantNameAttribute>True</Xaml.RemoveRedundantNameAttribute><Xaml.RemoveRedundantResource>True</Xaml.RemoveRedundantResource><Xaml.RemoveRedundantCollectionProperty>True</Xaml.RemoveRedundantCollectionProperty><Xaml.RemoveRedundantAttachedPropertySetter>True</Xaml.RemoveRedundantAttachedPropertySetter><Xaml.RemoveRedundantStyledValue>True</Xaml.RemoveRedundantStyledValue><Xaml.RemoveRedundantNamespaceAlias>True</Xaml.RemoveRedundantNamespaceAlias><Xaml.RemoveForbiddenResourceName>True</Xaml.RemoveForbiddenResourceName><Xaml.RemoveRedundantGridDefinitionsAttribute>True</Xaml.RemoveRedundantGridDefinitionsAttribute><Xaml.RemoveRedundantGridSpanAttribut>True</Xaml.RemoveRedundantGridSpanAttribut><Xaml.RemoveRedundantUpdateSourceTriggerAttribute>True</Xaml.RemoveRedundantUpdateSourceTriggerAttribute><Xaml.RemoveRedundantBindingModeAttribute>True</Xaml.RemoveRedundantBindingModeAttribute><FormatAttributeQuoteDescriptor>True</FormatAttributeQuoteDescriptor><CorrectVariableKindsDescriptor>True</CorrectVariableKindsDescriptor><VariablesToInnerScopesDescriptor>True</VariablesToInnerScopesDescriptor><StringToTemplatesDescriptor>True</StringToTemplatesDescriptor><RemoveRedundantQualifiersTs>True</RemoveRedundantQualifiersTs><OptimizeImportsTs>True</OptimizeImportsTs><OptimizeReferenceCommentsTs>True</OptimizeReferenceCommentsTs><PublicModifierStyleTs>True</PublicModifierStyleTs><ExplicitAnyTs>True</ExplicitAnyTs><TypeAnnotationStyleTs>True</TypeAnnotationStyleTs><RelativePathStyleTs>True</RelativePathStyleTs><AsInsteadOfCastTs>True</AsInsteadOfCastTs><CssAlphabetizeProperties>True</CssAlphabetizeProperties><JsInsertSemicolon>True</JsInsertSemicolon><JsReformatCode>True</JsReformatCode><JsFormatDocComments>True</JsFormatDocComments><HtmlReformatCode>True</HtmlReformatCode><AspOptimizeRegisterDirectives>True</AspOptimizeRegisterDirectives><VBOptimizeImports>True</VBOptimizeImports><VBShortenReferences>True</VBShortenReferences><RemoveCodeRedundancies>True</RemoveCodeRedundancies><CSUseAutoProperty>True</CSUseAutoProperty><CSMakeFieldReadonly>True</CSMakeFieldReadonly><CSArrangeQualifiers>True</CSArrangeQualifiers><CSFixBuiltinTypeReferences>True</CSFixBuiltinTypeReferences><CssReformatCode>True</CssReformatCode><VBReformatCode>True</VBReformatCode><VBFormatDocComments>True</VBFormatDocComments><CSOptimizeUsings><OptimizeUsings>True</OptimizeUsings><EmbraceInRegion>False</EmbraceInRegion><RegionName></RegionName></CSOptimizeUsings><CSShortenReferences>True</CSShortenReferences><CSReformatCode>True</CSReformatCode><CSharpFormatDocComments>True</CSharpFormatDocComments></Profile></s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeCleanup/SilentCleanupProfile/@EntryValue">FilterLists Cleanup</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/PLACE_SIMPLE_EMBEDDED_STATEMENT_ON_SAME_LINE/@EntryValue">NEVER</s:String>
|
||||
|
|
@ -10,5 +7,9 @@
|
|||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_CHAINED_BINARY_EXPRESSIONS/@EntryValue">CHOP_IF_LONG</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_CHAINED_METHOD_CALLS/@EntryValue">CHOP_IF_LONG</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_PARAMETERS_STYLE/@EntryValue">CHOP_IF_LONG</s:String>
|
||||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ECSharpKeepExistingMigration/@EntryIndexedValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ECSharpPlaceEmbeddedOnSameLineMigration/@EntryIndexedValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ECSharpUseContinuousIndentInsideBracesMigration/@EntryIndexedValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EMigrateBlankLinesAroundFieldToBlankLinesAroundProperty/@EntryIndexedValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/UserDictionary/Words/=Primariness/@EntryIndexedValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/UserDictionary/Words/=Syntaxes/@EntryIndexedValue">True</s:Boolean></wpf:ResourceDictionary>
|
||||
|
|
@ -1,4 +1,5 @@
|
|||
**/Dockerfile
|
||||
**/debug.Dockerfile
|
||||
**/.dockerignore
|
||||
**/.gitignore
|
||||
**/azure-pipelines.yaml
|
||||
|
|
|
|||
|
|
@ -2,8 +2,8 @@
|
|||
FROM nginx:alpine as base
|
||||
COPY server/conf.d /etc/nginx/conf.d
|
||||
|
||||
# init install
|
||||
FROM node:alpine as install
|
||||
# init build
|
||||
FROM node:alpine as build
|
||||
|
||||
# https://github.com/nodejs/docker-node/blob/master/docs/BestPractices.md#node-gyp-alpine
|
||||
RUN apk add --no-cache python make g++
|
||||
|
|
@ -13,13 +13,8 @@ WORKDIR /usr/src/app/
|
|||
COPY package*.json ./
|
||||
RUN npm ci --only=production
|
||||
|
||||
# init build
|
||||
FROM node:alpine as build
|
||||
WORKDIR /usr/src/app/
|
||||
COPY --from=install /usr/src/app/node_modules ./node_modules
|
||||
|
||||
# build
|
||||
COPY . .
|
||||
COPY . ./
|
||||
RUN npm run build
|
||||
|
||||
# final
|
||||
|
|
|
|||
13
web/debug.Dockerfile
Normal file
13
web/debug.Dockerfile
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
# init
|
||||
FROM node:alpine
|
||||
ENV PATH /app/node_modules/.bin:$PATH
|
||||
|
||||
# install
|
||||
RUN npm install react-scripts -g
|
||||
WORKDIR /usr/src/app/
|
||||
COPY package*.json ./
|
||||
RUN npm install
|
||||
|
||||
# start
|
||||
COPY . ./
|
||||
CMD ["npm", "start"]
|
||||
Loading…
Reference in a new issue