chore: Update docker, Minor Styling fix (#528)

* chore(docker): add .env and **/.env to .dockerignore
refactor(docker): remove unnecessary .env file copy and removal in Dockerfile

* style(AgentSettings): adjust Switch placement fix(EditPresetDialog): correctly show functions setting in preset
This commit is contained in:
Danny Avila 2023-06-17 11:38:48 -04:00 committed by GitHub
parent 9778e73087
commit f1f33de4db
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 5 additions and 8 deletions

View file

@ -1,3 +1,5 @@
**/node_modules **/node_modules
client/dist/images client/dist/images
data-node data-node
.env
**/.env

View file

@ -1,8 +1,6 @@
# Base node image # Base node image
FROM node:19-alpine AS node FROM node:19-alpine AS node
COPY . /app COPY . /app
# Copy .env file
COPY .env .env
# Install dependencies # Install dependencies
WORKDIR /app WORKDIR /app
RUN npm ci RUN npm ci
@ -11,9 +9,6 @@ RUN npm ci
ENV NODE_OPTIONS="--max-old-space-size=2048" ENV NODE_OPTIONS="--max-old-space-size=2048"
RUN npm run frontend RUN npm run frontend
# Remove .env file after build
RUN rm .env
# Node API setup # Node API setup
EXPOSE 3080 EXPOSE 3080
ENV HOST=0.0.0.0 ENV HOST=0.0.0.0

View file

@ -238,7 +238,7 @@ const EditPresetDialog = ({ open, onOpenChange, preset: _preset, title }) => {
)} )}
{preset?.endpoint === 'gptPlugins' && showAgentSettings && ( {preset?.endpoint === 'gptPlugins' && showAgentSettings && (
<AgentSettings <AgentSettings
agent={preset.agent} agent={preset.agentOptions.agent}
skipCompletion={preset.agentOptions.skipCompletion} skipCompletion={preset.agentOptions.skipCompletion}
model={preset.agentOptions.model} model={preset.agentOptions.model}
endpoint={preset.agentOptions.endpoint} endpoint={preset.agentOptions.endpoint}

View file

@ -65,7 +65,7 @@ function Settings(props) {
</div> </div>
<div className="grid w-full items-center gap-2 grid-cols-2"> <div className="grid w-full items-center gap-2 grid-cols-2">
<HoverCard openDelay={500}> <HoverCard openDelay={500}>
<HoverCardTrigger className='w-1/2'> <HoverCardTrigger className='w-[100px]'>
<label <label
htmlFor="functions-agent" htmlFor="functions-agent"
className="text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70 dark:text-gray-50" className="text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70 dark:text-gray-50"
@ -77,7 +77,7 @@ function Settings(props) {
<OptionHover type="func" side="right" /> <OptionHover type="func" side="right" />
</HoverCard> </HoverCard>
<HoverCard openDelay={500}> <HoverCard openDelay={500}>
<HoverCardTrigger className='w-1/2 ml-[-60px]'> <HoverCardTrigger className='w-[100px] ml-[-60px]'>
<label <label
htmlFor="skip-completion" htmlFor="skip-completion"
className="text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70 dark:text-gray-50" className="text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70 dark:text-gray-50"