# 1、准备公网上的测试数据库。

之前我们在Visual Studio里面调试的时候,使用的都是localhost的数据库。现在需要在公网上准备一个SQL Server。然后执行下面的步骤

1)把Study.BlazorOne.DbMigrator设置为启动项目;

2)修改appsettings.json中的连接字符串

将本地localhost的配置注释掉,加上公网的连接字符串

3)运行DbMigrator

# 2、为Study.BlazorOne.Blazor项目启用Dockers支持

# 3、在解决方案根目录下放置自动集成的配置文件

# 4、签入代码,尝试首次让gitlab的runner来构建Docker镜像

Gitlab中显示的完整信息如下

Running with gitlab-runner 15.11.0 (436955cb)
on gr05 YozfsKoh, system ID: r_QId06ioCL2oU
Preparing the "docker" executor 00:01
Using Docker executor with image proget.abcdefg.cn/gitlab/runner:7.0 ...
Authenticating with credentials from $DOCKER_AUTH_CONFIG
Pulling docker image proget.abcdefg.cn/gitlab/runner:7.0 ...
Using docker image sha256:79e3cb48a17b32ddebfbd69a5cee6f9f4cc0c9c3fb0dd669bd8bed8a6690de95 for proget.abcdefg.cn/gitlab/runner:7.0 with digest proget.loda.net.cn/gitlab/runner@sha256:a467584163ae036b191065de98fde78f378ef84ef06feef5be66f272e0b7504b ...
Preparing environment 00:01
Running on runner-yozfskoh-project-8-concurrent-0 via gr02...
Getting source from Git repository 00:01
Fetching changes with git depth set to 20...
Initialized empty Git repository in /builds/YozfsKoh/0/study/blazor-one/.git/
Created fresh repository.
Checking out 42f160af as detached HEAD (ref is main)...
Skipping Git submodules setup
Executing "step_script" stage of the job script 00:12
Using docker image sha256:79e3cb48a17b32ddebfbd69a5cee6f9f4cc0c9c3fb0dd669bd8bed8a6690de95 for proget.abcdefg.cn/gitlab/runner:7.0 with digest proget.abcdefg.cn/gitlab/runner@sha256:a467584163ae036b191065de98fde78f378ef84ef06feef5be66f272e0b7504b ...
$ docker login -u $DOCKER_DEV_USERNAME -p $DOCKER_DEV_PASSWORD $DOCKER_DEV_SERVER
WARNING! Using --password via the CLI is insecure. Use --password-stdin.
WARNING! Your password will be stored unencrypted in /root/.docker/config.json.
Configure a credential helper to remove this warning. See
https://docs.docker.com/engine/reference/commandline/login/#credentials-store
Login Succeeded
$ cd .
$ docker build -t $BLAZOR_DEV_REPO:$BLAZORONE_IMAGE_TAG -f src/Study.BlazorOne.Blazor/Dockerfile --no-cache .
Step 1/24 : FROM mcr.microsoft.com/dotnet/aspnet:7.0 AS base
7.0: Pulling from dotnet/aspnet
Get "https://mcr.microsoft.com/v2/dotnet/aspnet/manifests/sha256:136deb59fc62f52d7d9dde928cdefeaa7b25ef72c4e8bc8c56e676c6b5d7ab53": net/http: TLS handshake timeout
Cleaning up project directory and file based variables 00:01
ERROR: Job failed: exit code 1

卡在了最后一步,就是从microsoft.com下载aspnet:7.0的基础镜像的时候,TLS握手超时。

简单,我们在自己的私有docker registry中放置这个aspnet:7.0的基础镜像即可。

然后修改Study.BlazorOne.Blazor项目的Dockerfile文件,改动第3行和第8行,指向我们修改过后的基础镜像:

签入代码。Gitlab的Runner立即尝试自动构建。

# 5、看起来顺利构建,但是还是卡在最后一步:

a0acdda47b2a: Retrying in 1 second
e2fed13a1ac3: Retrying in 1 second
03cef3692ade: Retrying in 1 second
39d424e26f18: Waiting
unknown: Could not resolve ProGet feed "study". Docker repository names in ProGet must include the feed as a prefix. Example: MyFeed/library/ubuntu
Cleaning up project directory and file based variables 00:01
ERROR: Job failed: exit code 1

这个错误的意思,是我们指定的路径是用于上传NuGet包的,不能用于推送Docker镜像。重新在ProGet里面创建新的Feed,用于储存Docker的构建的成果。然后修改.gitlab-ci.yml中的变量。修改了下图第9行的URL:

签入代码,Gitlab中立即调用了Runner,成功自动构建。

# 6、上图显示,自动集成任务的第一步,构建Docker镜像是成功了,第二步报错。

错误信息如下:

Running with gitlab-runner 15.11.0 (436955cb)
on gr05 YozfsKoh, system ID: r_QId06ioCL2oU
Preparing the "docker" executor 00:01
Using Docker executor with image proget.abcdefg.cn/gitlab/runner:7.0 ...
Authenticating with credentials from $DOCKER_AUTH_CONFIG
Pulling docker image proget.abcdefg.cn/gitlab/runner:7.0 ...
Using docker image sha256:79e3cb48a17b32ddebfbd69a5cee6f9f4cc0c9c3fb0dd669bd8bed8a6690de95 for proget.abcdefg.cn/gitlab/runner:7.0 with digest proget.abcdefg.cn/gitlab/runner@sha256:a467584163ae036b191065de98fde78f378ef84ef06feef5be66f272e0b7504b ...
Preparing environment 00:01
Running on runner-yozfskoh-project-8-concurrent-0 via gr02...
Getting source from Git repository 00:01
Fetching changes with git depth set to 20...
Reinitialized existing Git repository in /builds/YozfsKoh/0/study/blazor-one/.git/
Checking out 0087e923 as detached HEAD (ref is main)...
Skipping Git submodules setup
Restoring cache 00:00
Checking cache for default-protected...
No URL provided, cache will not be downloaded from shared cache server. Instead a local version of cache will be extracted.
Successfully extracted cache
Executing "step_script" stage of the job script 00:01
Using docker image sha256:79e3cb48a17b32ddebfbd69a5cee6f9f4cc0c9c3fb0dd669bd8bed8a6690de95 for proget.abcdefg.cn/gitlab/runner:7.0 with digest proget.abcdefg.cn/gitlab/runner@sha256:a467584163ae036b191065de98fde78f378ef84ef06feef5be66f272e0b7504b ...
$ mkdir -p ~/.ssh
$ chmod 700 ~/.ssh
$ cd /root/.ssh
$ cp /home/gitlab-runner/ssh/* .
$ echo "部署到Brain测试站……"
部署到Brain测试站……
$ cd /home/gitlab-runner/scripts
$ bash ssh-deploy.sh blazor_one_test 8606 80 $BLAZOR_DEV_REPO:$BLAZORONE_IMAGE_TAG amisoft $DOCKER_DEV_SERVER $DOCKER_DEV_USERNAME $DOCKER_DEV_PASSWORD $SSH_AUTO_LOGIN_USER $TEST_APP_SERVER
docker容器实例名称: blazor_one_test
目标服务器对外端口号 8606
docker容器开放端口号 80
docker镜像URL proget.abcdefg.cn/study-images/blazor:15
容器启动配置环境 amisoft
Docker服务器DNS名称 proget.abcdefg.cn
登入Docker服务器的用户名称 usernamexxxxx
登入Docker服务器的密码 myPassword
SSH自动登入目标服务器使用的用户名 username
SSH自动登入的目标服务器 proget.abcdefg.cn
在服务器上执行的命令是
docker run -d --privileged=true --restart=always -d --name blazor_one_test -v /mnt/data/yee-change:/var/config -e ASPNETCORE_ENVIRONMENT=amisoft -p 8606:80 proget.abcdefg.cn/study-images/blazor:15
Pseudo-terminal will not be allocated because stdin is not a terminal.
Warning: Permanently added 'proget.abcdefg.cn,47.106.133.5' (ECDSA) to the list of known hosts.
Permission denied, please try again.
Permission denied, please try again.
username@proget.abcdefg.cn: Permission denied (publickey,password).
Cleaning up project directory and file based variables 00:01
ERROR: Job failed: exit code 1

很清楚,SSH登入服务器的时候,被拒绝了。

# 7、让Gitlab的Runner能自动登入用于运行容器的测试服务器

很简单,在服务器上创建名为tommy的linux用户,在该用户的/home/tommy/.ssh文件夹的密钥文件里,加入我们的公钥

# 8、再次触发自动集成

得到如下错误:

Welcome to Alibaba Cloud Elastic Compute Service !
The programs included with the Ubuntu system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.
Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by
applicable law.
bash: /home/great/docker/gitlab/runner/deploy.sh: No such file or directory
Cleaning up project directory and file based variables 00:01
ERROR: Job failed: exit code 1

上述错误很简单,是服务器的/home/greate/docker/gitlab/runner这个目录下,没有deploy.sh这个脚本,这个脚本的内容如下:

#!/bin/bash
conName=$1
eonPort=$2
conPort=$3
images=$4
count=`docker ps -a |grep "$conName"|wc -l `
if [ $count -eq 0 ];then
echo "$conName container is not exit"
else
id=$(docker ps -a |grep "$conName" |awk '{print $1}')
for i in $id
do
docker stop $i
docker rm $i
done
fi
docker rmi $images
docker login -u david -p NXbdusoeiu*2349243_ded docker.amicap.cn
docker run --restart=always -d --name $conName -v /mnt/config:/var/config -e ASPNETCORE_ENVIRONMENT=$5 -p $eonPort:$conPort $images

拷贝到服务器后,记得改一下权限。

# 9、再次触发自动集成

在Gitlab中的完整日志控制台输出如下

Running with gitlab-runner 15.11.0 (436955cb)
on gr05 YozfsKoh, system ID: r_QId06ioCL2oU
Preparing the "docker" executor 00:01
Using Docker executor with image proget.abcdefg.cn/gitlab/runner:7.0 ...
Authenticating with credentials from $DOCKER_AUTH_CONFIG
Pulling docker image proget.abcdefg.cn/gitlab/runner:7.0 ...
Using docker image sha256:79e3cb48a17b32ddebfbd69a5cee6f9f4cc0c9c3fb0dd669bd8bed8a6690de95 for proget.abcdefg.cn/gitlab/runner:7.0 with digest proget.abcdefg.cn/gitlab/runner@sha256:a467584163ae036b191065de98fde78f378ef84ef06feef5be66f272e0b7504b ...
Preparing environment 00:00
Running on runner-yozfskoh-project-8-concurrent-0 via gr02...
Getting source from Git repository 00:01
Fetching changes with git depth set to 20...
Reinitialized existing Git repository in /builds/YozfsKoh/0/study/blazor-one/.git/
Checking out b34700f3 as detached HEAD (ref is main)...
Skipping Git submodules setup
Restoring cache 00:01
Checking cache for default-protected...
No URL provided, cache will not be downloaded from shared cache server. Instead a local version of cache will be extracted.
Successfully extracted cache
Executing "step_script" stage of the job script 00:01
Using docker image sha256:79e3cb48a17b32ddebfbd69a5cee6f9f4cc0c9c3fb0dd669bd8bed8a6690de95 for proget.abcdefg.cn/gitlab/runner:7.0 with digest proget.abcdefg.cn/gitlab/runner@sha256:a467584163ae036b191065de98fde78f378ef84ef06feef5be66f272e0b7504b ...
$ mkdir -p ~/.ssh
$ chmod 700 ~/.ssh
$ cd /root/.ssh
$ cp /home/gitlab-runner/ssh/* .
$ echo "部署到Brain测试站……"
部署到Brain测试站……
$ cd /home/gitlab-runner/scripts
$ bash ssh-deploy.sh blazor_one_test 8606 80 $BLAZOR_DEV_REPO:$BLAZORONE_IMAGE_TAG amisoft $DOCKER_DEV_SERVER $DOCKER_DEV_USERNAME $DOCKER_DEV_PASSWORD $SSH_AUTO_LOGIN_USER $TEST_APP_SERVER
docker容器实例名称: blazor_one_test
目标服务器对外端口号 8606
docker容器开放端口号 80
docker镜像URL proget.abcdefg.cn/study-images/blazor:17
容器启动配置环境 amisoft
Docker服务器DNS名称 proget.abcdefg.cn
登入Docker服务器的用户名称 username@docker
登入Docker服务器的密码 MySecretPassword
SSH自动登入目标服务器使用的用户名 great
SSH自动登入的目标服务器 proget.abcdefg.cn
在服务器上执行的命令是
docker run -d --privileged=true --restart=always -d --name blazor_one_test -v /mnt/data/yee-change:/var/config -e ASPNETCORE_ENVIRONMENT=amisoft -p 8606:80 proget.abcdefg.cn/study-images/blazor:17
Pseudo-terminal will not be allocated because stdin is not a terminal.
Warning: Permanently added 'proget.abcdefg.cn,47.106.133.5' (ECDSA) to the list of known hosts.
Permission denied, please try again.
Permission denied, please try again.
great@proget.abcdefg.cn: Permission denied (publickey,password).
Cleaning up project directory and file based variables 00:00
ERROR: Job failed: exit code 1

# 10、如果Gitlab的Runner不联络服务器,不领取工作

可以执行下面两个命令

root@dev-server:~# docker exec -it gr02 gitlab-runner verify
Runtime platform arch=amd64 os=linux pid=7 revision=436955cb version=15.11.0
Running in system-mode. Verifying runner... is alive runner=YozfsKoh
root@dev-server:~# docker exec -it gr02 gitlab-runner restart
Runtime platform arch=amd64 os=linux pid=28 revision=436955cb version=15.11.0

# 11、登入被拒绝

查了很多文件,也没搞定。于是换了一台测试服务器。成功发布

Running with gitlab-runner 15.11.0 (436955cb)
on gr05 YozfsKoh, system ID: r_QId06ioCL2oU
Preparing the "docker" executor 00:01
Using Docker executor with image proget.abcdefg.cn/gitlab/runner:7.0 ...
Authenticating with credentials from $DOCKER_AUTH_CONFIG
Pulling docker image proget.abcdefg.cn/gitlab/runner:7.0 ...
Using docker image sha256:79e3cb48a17b32ddebfbd69a5cee6f9f4cc0c9c3fb0dd669bd8bed8a6690de95 for proget.abcdefg.cn/gitlab/runner:7.0 with digest proget.abcdefg.cn/gitlab/runner@sha256:a467584163ae036b191065de98fde78f378ef84ef06feef5be66f272e0b7504b ...
Preparing environment 00:00
Running on runner-yozfskoh-project-8-concurrent-0 via gr02...
Getting source from Git repository 00:01
Fetching changes with git depth set to 20...
Reinitialized existing Git repository in /builds/YozfsKoh/0/study/blazor-one/.git/
Checking out 832423e6 as detached HEAD (ref is main)...
Skipping Git submodules setup
Restoring cache 00:01
Checking cache for default-protected...
No URL provided, cache will not be downloaded from shared cache server. Instead a local version of cache will be extracted.
Successfully extracted cache
Executing "step_script" stage of the job script 00:39
Using docker image sha256:79e3cb48a17b32ddebfbd69a5cee6f9f4cc0c9c3fb0dd669bd8bed8a6690de95 for proget.abcdefg.cn/gitlab/runner:7.0 with digest proget.abcdefg.cn/gitlab/runner@sha256:a467584163ae036b191065de98fde78f378ef84ef06feef5be66f272e0b7504b ...
$ mkdir -p ~/.ssh
$ chmod 700 ~/.ssh
$ cd /root/.ssh
$ cp /home/gitlab-runner/ssh/* .
$ echo "部署到Brain测试站……"
部署到Brain测试站……
$ cd /home/gitlab-runner/scripts
$ bash ssh-deploy.sh blazor_one_test 8606 80 $BLAZOR_DEV_REPO:$BLAZORONE_IMAGE_TAG AliyunTest $DOCKER_DEV_SERVER $DOCKER_DEV_USERNAME $DOCKER_DEV_PASSWORD $SSH_AUTO_LOGIN_USER $TEST_APP_SERVER
docker容器实例名称: blazor_one_test
目标服务器对外端口号 8606
docker容器开放端口号 80
docker镜像URL proget.abcdefg.cn/study-images/blazor:22
容器启动配置环境 AliyunTest
Docker服务器DNS名称 proget.abcdefg.cn
登入Docker服务器的用户名称 username@docker
登入Docker服务器的密码 MySecret123
SSH自动登入目标服务器使用的用户名 david
SSH自动登入的目标服务器 172.16.0.199
在服务器上执行的命令是
docker run -d --privileged=true --restart=always -d --name blazor_one_test -v /mnt/data/yee-change:/var/config -e ASPNETCORE_ENVIRONMENT=AliyunTest -p 8606:80 proget.abcdefg.cn/study-images/blazor:22
Pseudo-terminal will not be allocated because stdin is not a terminal.
Warning: Permanently added '172.16.0.199' (ECDSA) to the list of known hosts.
Welcome to Ubuntu 22.04.2 LTS (GNU/Linux 5.15.0-72-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Sun May 21 07:07:31 PM UTC 2023
System load: 1.8740234375
Usage of /: 43.6% of 97.87GB
Memory usage: 21%
Swap usage: 0%
Temperature: 76.0 C
Processes: 495
Users logged in: 1
IPv4 address for br-520215db1f30: 172.20.0.1
IPv4 address for br-5be0717938c9: 172.19.0.1
IPv4 address for br-76c941d48dc2: 10.10.3.1
IPv4 address for br-f98ed0d36211: 172.18.0.1
IPv4 address for docker0: 172.17.0.1
IPv4 address for enp86s0: 172.16.0.199
* Strictly confined Kubernetes makes edge and IoT secure. Learn how MicroK8s
just raised the bar for easy, resilient and secure K8s cluster deployment.
https://ubuntu.com/engage/secure-kubernetes-at-the-edge
Expanded Security Maintenance for Applications is not enabled.
1 update can be applied immediately.
To see these additional updates run: apt list --upgradable
Enable ESM Apps to receive additional future security updates.
See https://ubuntu.com/esm or run: sudo pro status
4a109ae04f06
4a109ae04f06
Untagged: proget.abcdefg.cn/study-images/blazor:22
Untagged: proget.abcdefg.cn/study-images/blazor@sha256:44721bba14a6d98370582bb875eedb8a20809febe60e64169fee767b5edee0de
Deleted: sha256:0979c4238750443e1e0174fb1dfae269fac53e701eea075ec09baa8e921ff258
Deleted: sha256:bc05348c1108ee9a0c7d92cbd13fab85cdec49a9e540b462e06298f1eb82b3fb
Deleted: sha256:b6692a838b82591c27920dee0e947bb5b221843b983644e2b4555e5e0f37362b
Deleted: sha256:5012a44cce34ce6e752a17db8d5c935e336e84f78239389e756d1163790c1fb5
Deleted: sha256:08c9e070d99c38128ba4615a7f30a31349a09f95323e075f1456fd97a9a3e8e5
Deleted: sha256:6a3a81deb5e13495f765faaccceab8a4f46a82caa7ae4968a7bc7fea973431dc
Deleted: sha256:86de30b98c0d4a0999180ff2971a9a7269596d90d9484048f49757c1ac90ec35
Deleted: sha256:9221e97be3386aa9ad1d2c386919536261cb30ed0117bc300894b542f344cd9d
WARNING! Using --password via the CLI is insecure. Use --password-stdin.
WARNING! Your password will be stored unencrypted in /home/david/.docker/config.json.
Configure a credential helper to remove this warning. See
https://docs.docker.com/engine/reference/commandline/login/#credentials-store
Login Succeeded
Unable to find image 'proget.abcdefg.cn/study-images/blazor:22' locally
22: Pulling from study-images/blazor
9e3ea8720c6d: Already exists
2436f232d040: Already exists
9a2730c0a140: Already exists
6bb6cfc88137: Already exists
8bc8046fd854: Already exists
5016cd0016e4: Already exists
59395839e470: Already exists
19dc23f69568: Already exists
71f1b4b01e35: Already exists
1868690bc889: Already exists
371a028335d5: Already exists
c110905bfc27: Already exists
63d18f70c3d6: Already exists
424a907a98a6: Already exists
a2552f8f5db0: Already exists
cd1c5a79ba5c: Already exists
aefe6775f233: Already exists
31a7c2980e89: Already exists
df0689172fdf: Pulling fs layer
658b7d3a4525: Pulling fs layer
df0689172fdf: Verifying Checksum
df0689172fdf: Pull complete
658b7d3a4525: Verifying Checksum
658b7d3a4525: Download complete
658b7d3a4525: Pull complete
Digest: sha256:44721bba14a6d98370582bb875eedb8a20809febe60e64169fee767b5edee0de
Status: Downloaded newer image for proget.abcdefg.cn/study-images/blazor:22
bc571017f1006bdaed1c000110199d95d0d5c1a6cd7609bc9c26b7a938b9dd29
Saving cache for successful job 00:01
Creating cache default-protected...
WARNING: node_modules/: no matching files. Ensure that the artifact path is relative to the working directory (/builds/YozfsKoh/0/study/blazor-one)
Archive is up to date!
Created cache
Cleaning up project directory and file based variables 00:01
Job succeeded

12、在测试服务器上,运行docker logs blazor_one_test

发现不停的报如下错误:

[18:57:26 FTL] Host terminated unexpectedly!
Volo.Abp.AbpInitializationException: An error occurred during ConfigureServicesAsync phase of the module Volo.Abp.OpenIddict.AbpOpenIddictAspNetCoreModule, Volo.Abp.OpenIddict.AspNetCore, Version=7.2.2.0, Culture=neutral, PublicKeyToken=null. See the inner exception for details.
---> System.IO.FileNotFoundException: Signing Certificate couldn't found: /app/authserver.pfx
at Study.BlazorOne.Blazor.BlazorOneBlazorModule.GetSigningCertificate(IWebHostEnvironment hostingEnv, IConfiguration configuration) in /src/src/Study.BlazorOne.Blazor/BlazorOneBlazorModule.cs:line 357
at Study.BlazorOne.Blazor.BlazorOneBlazorModule.<>c__DisplayClass0_0.<PreConfigureServices>b__3(OpenIddictServerBuilder builder) in /src/src/Study.BlazorOne.Blazor/BlazorOneBlazorModule.cs:line 128
at Volo.Abp.Options.PreConfigureActionList`1.Configure(TOptions options)
at Microsoft.Extensions.DependencyInjection.ServiceCollectionPreConfigureExtensions.ExecutePreConfiguredActions[TOptions](IServiceCollection services, TOptions options)
at Volo.Abp.OpenIddict.AbpOpenIddictAspNetCoreModule.<>c__DisplayClass1_0.<AddOpenIddictServer>b__0(OpenIddictServerBuilder builder)
at Microsoft.Extensions.DependencyInjection.OpenIddictServerExtensions.AddServer(OpenIddictBuilder builder, Action`1 configuration)
at Volo.Abp.OpenIddict.AbpOpenIddictAspNetCoreModule.AddOpenIddictServer(IServiceCollection services)
at Volo.Abp.OpenIddict.AbpOpenIddictAspNetCoreModule.ConfigureServices(ServiceConfigurationContext context)
at Volo.Abp.Modularity.AbpModule.ConfigureServicesAsync(ServiceConfigurationContext context)
at Volo.Abp.AbpApplicationBase.ConfigureServicesAsync()
--- End of inner exception stack trace ---
at Volo.Abp.AbpApplicationBase.ConfigureServicesAsync()
at Volo.Abp.AbpApplicationFactory.CreateAsync[TStartupModule](IServiceCollection services, Action`1 optionsAction)
at Microsoft.Extensions.DependencyInjection.ServiceCollectionApplicationExtensions.AddApplicationAsync[TStartupModule](IServiceCollection services, Action`1 optionsAction)
at Microsoft.Extensions.DependencyInjection.WebApplicationBuilderExtensions.AddApplicationAsync[TStartupModule](WebApplicationBuilder builder, Action`1 optionsAction)
at Study.BlazorOne.Blazor.Program.Main(String[] args) in /src/src/Study.BlazorOne.Blazor/Program.cs:line 36

未完待续。

用Docker发布Study.BlazorOne.Blazor到公网测试服务器的更多相关文章

  1. .NET Core使用skiasharp文字头像生成方案(基于docker发布)

    一.问题背景 目前.NET Core下面针对于图像处理的库微软并没有集成,在.NET FrameWork下我们已经习惯使用System.Drawing类库做简单的图像处理,到了.NET Core下一脸 ...

  2. Docker 发布 Abp net core web 服务

    Docker 发布 Abp net core web 服务 准备工作:Abp 项目,这个是模板下载地址 https://aspnetboilerplate.com/Templates (本例使用的是S ...

  3. docker 发布方式尝试

    docker 发布方式尝试 目前有个小项目, 尝试用docker的方式来发布, 项目只有一个节点, 使用 kubenate 有点小题大做, 所以采用docker-compose来发布. 发布过程 GI ...

  4. docker 发布应用时添加 git revision

    概要 实施步骤 获取 git revision 前端 git revision 注入 后端 git revision 注入 概要 docker 发布应用时, 将 git revision 注入到应用中 ...

  5. Jenkins+Harbor+Docker发布

    使用Jenkins发布Docke 需要准备的,docker,jenkins,Harbor docker安装 安装依赖: # yum install -y yum-utils device-mapper ...

  6. 结合docker发布后端项目(基于gradle包管理)的shell脚本

    结合docker发布后端项目(基于gradle包管理)的shell脚本 本教程依据个人理解并经过实际验证为正确,特此记录下来,权当笔记. 注:基于linux操作系统(敏感信息都进行了处理) 目前主流的 ...

  7. 结合docker发布前端项目(基于npm包管理)的shell脚本

    结合docker发布前端项目(基于npm包管理)的shell脚本 本教程依据个人理解并经过实际验证为正确,特此记录下来,权当笔记. 注:基于linux操作系统 目前主流的前后端分离的项目中,常常在部署 ...

  8. docker发布.net core程序的坑

    docker发布遇到的两个问题 1:Could not resolve CoreCLR path. For more details, enable tracing by setting COREHO ...

  9. Angular入门到精通系列教程(14)- Angular 编译打包 & Docker发布

    目录 1. 概要 2. 编译打包 2.1. 基本打包命令 2.2. 打包部署到二级目录 3. Angular站点的发布 3.1. web服务器发布 3.2. 使用docker发布 4. 总结 环境: ...

  10. 使用Docker发布blazor wasm

    Blazor编译后的文件是静态文件,所以我们只需要一个支持静态页面的web server即可. 根据不同项目,会用不同的容器编排,本文已无网关的情况下为例,一步一步展示如何打包进docker 需求 H ...

随机推荐

  1. [转帖]【JVM】常用虚拟机参数及实例

    常用参数表 参数 描述 -XX:+PrintGC 启动java虚拟机后,只要遇到gc,就打印日志 -XX:+PrintGCDetails gc发生时,打印更详细的日志 -XX:+PrintHeapAt ...

  2. 基于Apache PDFBox的PDF数字签名

    在Java语言环境中完成数字签名主要基于itext-pdf.PDFBox两种工具,itext-pdf受商业限制,应用于商业服务中需要购买授权.PDFBox是apache基金会开源项目,基于apache ...

  3. vue中$children的理解

    官网介绍 $children $children 获取当前实例的直接子组件 .需要注意 $children 并不保证顺序,也不是响应式的.[特别重要] 如果你发现自己正在尝试使用 $children ...

  4. 在K8S中,静态、动态、自主式Pod有何区别?

    在Kubernetes(简称K8s)中,静态Pod.自主式Pod和动态Pod是不同管理方式下的Pod类型,它们的区别主要体现在创建和管理方式上: 静态Pod: 静态Pod是由kubelet直接管理的, ...

  5. SpringAll

    目录 Spring Cloud 01-初识SpringCloud与微服务 02-SpringCloud-Feign声明式服务的调用 Spring Security 01-SpringSecurity- ...

  6. 小白学k8s(11)-k8s中Secret理解

    理解Secret 什么是Secret Secret的类型 Opaque Secret Opaque Secret的使用 将Secret挂载到Volume中 挂载的Secret会被自动更新 将Secre ...

  7. 解决SystemExit: 2,args = parser.parse_args() 的问题,

    报错: File "/home/barry/PycharmProjects/EEPC/detect.py", line 283, in parse_opt opt = parser ...

  8. Github搜索代码技巧

    ↵相关链接: 码云(gitee)配置SSH密钥 码云gitee创建仓库并用git上传文件 git 上传错误This oplation equires one of the flowi vrsionso ...

  9. webrtc终极版(一)5分钟搭建多人实时会议系统webrtc

    webrtc终极版(一),支持https,在线部署[不是本地demo],采用RTCMultiConnection官方demo,5分钟即可搭建成功 @ 目录 webrtc终极版(一),支持https,在 ...

  10. 4.2使用IDA Pro分析实战--《恶意代码分析实战》

    使用 IDA Pro 分析 Lab05-01.dll 1.DllMain的地址是什么? 2.使用Imports窗口并浏览到的gethostbyname,导入函数定位到什么地址? 3.有多少函数调用了g ...