jsimport { NestFactory } from '@nestjs/core'
import { Controller, Get, Module } from '@nestjs/common'
import { LoggerModule, Logger } from 'nestjs-pino'
@Controller()
export class AppController {
constructor(private readonly logger: Logger) {} 使用
@Get()
getHello() {
this.logger.log('something')
return `Hello world`
}
}
@Module({
controllers: [AppController],
imports: [LoggerModule.forRoot()] // 导入
})
class MyModule {}
async function bootstrap() {
const app = await NestFactory.create(MyModule)
await app.listen(3000)
}
bootstrap()
jsimport {
defineConfig,
presetAttributify,
presetIcons,
presetTypography,
presetUno,
presetWebFonts,
transformerDirectives,
transformerVariantGroup,
} from "unocss";
js1.
git clone https://github.com/acmesh-official/acme.sh.git
cd acme.sh
./acme.sh --install -m qq.com
2. 直接签发
acme.sh --issue -d xueqi666.com --webroot 网站的/路径
(acme.sh --set-default-ca --server letsencrypt)ZeroSSL太慢了
3.运行
acme.sh --install-cert -d xueqi666.top \
--key-file /home/xq/openresty/conf/tls/xueqi666.top.key \
--cert-file /home/xq/openresty/conf/tls/xueqi666.top.cer \
--fullchain-file /home/xq/openresty/conf/tls/fullchain.cer \
--reloadcmd "docker restart openresty"
安装证书
4.配置openrestry
ssl_certificate /usr/local/openresty/nginx/tls/fullchain.cer;
ssl_certificate_key /usr/local/openresty/nginx/tls/xueqi666.top.key;
5.查看定时任务60天自动申请一次
crontab -e