This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const cld = new Cloudinary({ | |
cloud: { | |
cloudName: "slashclick", | |
}, | |
}); | |
const myImage = cld.image(popout); | |
const srcSetOptions = [ | |
{ width: 200, transformation: scale().width(200) }, | |
{ width: 400, transformation: scale().width(400) }, | |
{ width: 600, transformation: scale().width(600) }, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { User as DefaultUser } from '@auth/core/types' | |
import { AdapterUser as DefaultAdapterUser } from '@auth/core/adapters' | |
import Google from 'next-auth/providers/google' | |
import Facebook from 'next-auth/providers/facebook' | |
import Apple from 'next-auth/providers/apple' | |
import EmailProvider, { EmailConfig } from 'next-auth/providers/email' | |
import NextAuth from 'next-auth' | |
import type { NextAuthConfig } from 'next-auth' | |
// import GitHub from 'next-auth/providers/github' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Had same problem on COPY --from=builder /app/out/full/ . line as everyone else using pnpm. | |
Added **/node_modules to root .dockerignore to resolve. | |
Then ran into issues with the last 3 COPY lines. Needed to also copy the next.config.js from the with-docker example. tldr- I was missing output: standalone | |
Ended up with this. I like it because pnpm and turbo are pulled to "base", allowing me to just use bare alpine in the end result. | |
copied from the with-docker example and updated to use pnpm. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jest.useFakeTimers().setSystemTime(new Date('2023-01-01')); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
AWSTemplateFormatVersion: "2010-09-09" | |
Parameters: | |
SubnetID: | |
Type: String | |
Resources: | |
Cluster: | |
Type: AWS::ECS::Cluster | |
Properties: | |
ClusterName: deployment-example-cluster | |
LogGroup: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//@testing-library/react-hooks package will help to test hooks functionalities. | |
const { result, waitForNextUpdate } = renderHook(() => useCustomHooks()); | |
act(() => { | |
result.current[0]('123'); | |
}); | |
await waitForNextUpdate(); | |
expect(result.current[1].isSuccess).toBe(true); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
########## | |
## DEPS ## | |
########## | |
FROM node:16-alpine AS deps | |
RUN apk add --no-cache libc6-compat | |
WORKDIR /app | |
# Install dependencies based on the preferred package manager | |
COPY package.json yarn.lock* package-lock.json* pnpm-lock.yaml* ./ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Description: Animals4Life base VPC Template + Boostrapped Wordpress (requires VPC_EFS_AURORA in CREATE_COMPLETE) | |
Parameters: | |
LatestAmiId: | |
Description: AMI for Wordpess Instance (default is latest AmaLinux2) | |
Type: 'AWS::SSM::Parameter::Value<AWS::EC2::Image::Id>' | |
Default: '/aws/service/ami-amazon-linux-latest/amzn2-ami-hvm-x86_64-gp2' | |
DBName: | |
AllowedPattern: '[a-zA-Z][a-zA-Z0-9]*' | |
ConstraintDescription: must begin with a letter and contain only alphanumeric characters. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Description: Animals4Life base VPC Template + EFS + Aurora DB Cluster | |
Parameters: | |
LatestAmiId: | |
Description: AMI for Wordpess Instance (default is latest AmaLinux2) | |
Type: 'AWS::SSM::Parameter::Value<AWS::EC2::Image::Id>' | |
Default: '/aws/service/ami-amazon-linux-latest/amzn2-ami-hvm-x86_64-gp2' | |
DBName: | |
AllowedPattern: '[a-zA-Z][a-zA-Z0-9]*' | |
ConstraintDescription: must begin with a letter and contain only alphanumeric characters. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wget https://s3.amazonaws.com/amazoncloudwatch-agent/amazon_linux/amd64/latest/amazon-cloudwatch-agent.rpm | |
sudo rpm -U ./amazon-cloudwatch-agent.rpm | |
# IAM ROLE | |
EC2 Role | |
EC2 | |
CloudWatchAgentServerPolicy |
NewerOlder