Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

苹果电脑该如何部署?有没有相关的文档或者文章。 #149

Open
XiuXiang-GitHub opened this issue Nov 3, 2023 · 16 comments

Comments

@XiuXiang-GitHub
Copy link

No description provided.

@kklldog
Copy link
Collaborator

kklldog commented Nov 3, 2023

docker run 吧,如果是 x86 就用默认的镜像。如果是 M CPU,就选 ARM 的镜像。如果是本地跑,那就下载源码自己编译 osx64 的产物。
https://learn.microsoft.com/en-us/dotnet/core/tools/dotnet-publish

@XiuXiang-GitHub
Copy link
Author

好的,谢谢

@XiuXiang-GitHub
Copy link
Author

2023-11-03 21:28:10 current dir path: /app/
2023-11-03 21:28:10 【FreeSql: Master Database】Next recovery time:11/03/2023 21:28:12
2023-11-03 21:28:10 Unhandled exception. System.TypeInitializationException: The type initializer for 'AgileConfig.Server.Service.JwtService' threw an exception.
2023-11-03 21:28:10 ---> System.TypeInitializationException: The type initializer for 'AgileConfig.Server.Data.Freesql.FreeSQL' threw an exception.
2023-11-03 21:28:10 ---> System.Exception: FreeSql: The FreeSql: Master Database status is unavailable and cannot be used until the background checker is restored. FreeSql: Connection string error, or check project properties > Build > Target Platform: x86 | x64, Or use FreeSql.Provider.SqliteCore accessing arm platform
2023-11-03 21:28:10 ---> System.Exception: FreeSql: The FreeSql: Master Database status is unavailable and cannot be used until the background checker is restored. FreeSql: Connection string error, or check project properties > Build > Target Platform: x86 | x64, Or use FreeSql.Provider.SqliteCore accessing arm platform
2023-11-03 21:28:10 ---> System.Exception: FreeSql: Connection string error, or check project properties > Build > Target Platform: x86 | x64, Or use FreeSql.Provider.SqliteCore accessing arm platform
2023-11-03 21:28:10 --- End of inner exception stack trace ---
2023-11-03 21:28:10 at FreeSql.Internal.ObjectPool.ObjectPool1.GetFree(Boolean checkAvailable) 2023-11-03 21:28:10 at FreeSql.Internal.ObjectPool.ObjectPool1.Get(Nullable1 timeout) 2023-11-03 21:28:10 at FreeSql.Internal.CommonProvider.AdoProvider.ExecuteScalar(DbConnection connection, DbTransaction transaction, CommandType cmdType, String cmdText, Int32 cmdTimeout, DbParameter[] cmdParms) 2023-11-03 21:28:10 --- End of inner exception stack trace --- 2023-11-03 21:28:10 at FreeSql.Internal.CommonProvider.AdoProvider.LoggerException(IObjectPool1 pool, PrepareCommandResult pc, Exception ex, DateTime dt, StringBuilder logtxt, Boolean isThrowException)
2023-11-03 21:28:10 at FreeSql.Internal.CommonProvider.AdoProvider.ExecuteScalar(DbConnection connection, DbTransaction transaction, CommandType cmdType, String cmdText, Int32 cmdTimeout, DbParameter[] cmdParms)
2023-11-03 21:28:10 at FreeSql.Internal.CommonProvider.AdoProvider.ExecuteScalar(String cmdText, Object parms)
2023-11-03 21:28:10 at AgileConfig.Server.Data.Freesql.EnsureTables.ExistTable(IFreeSql instance) in /src/AgileConfig.Server.Data.Freesql/EnsureTables.cs:line 52
2023-11-03 21:28:10 at AgileConfig.Server.Data.Freesql.EnsureTables.Ensure(IFreeSql instance) in /src/AgileConfig.Server.Data.Freesql/EnsureTables.cs:line 63
2023-11-03 21:28:10 at AgileConfig.Server.Data.Freesql.FreeSQL..cctor() in /src/AgileConfig.Server.Data.Freesql/FreeSQL.cs:line 20
2023-11-03 21:28:10 --- End of inner exception stack trace ---
2023-11-03 21:28:10 at AgileConfig.Server.Data.Freesql.FreeSQL.get_Instance() in /src/AgileConfig.Server.Data.Freesql/FreeSQL.cs:line 23
2023-11-03 21:28:10 at AgileConfig.Server.Service.JwtService..cctor() in /src/AgileConfig.Server.Service/JwtService.cs:line 20
2023-11-03 21:28:10 --- End of inner exception stack trace ---
2023-11-03 21:28:10 at AgileConfig.Server.Service.JwtService..ctor()
2023-11-03 21:28:10 at AgileConfig.Server.Apisite.Startup.ConfigureServices(IServiceCollection services) in /src/AgileConfig.Server.Apisite/Startup.cs:line 50
2023-11-03 21:28:10 at System.RuntimeMethodHandle.InvokeMethod(Object target, Span1& arguments, Signature sig, Boolean constructor, Boolean wrapExceptions) 2023-11-03 21:28:10 at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) 2023-11-03 21:28:10 at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.InvokeCore(Object instance, IServiceCollection services) 2023-11-03 21:28:10 at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.<>c__DisplayClass9_0.<Invoke>g__Startup|0(IServiceCollection serviceCollection) 2023-11-03 21:28:10 at Microsoft.AspNetCore.Hosting.StartupLoader.ConfigureServicesDelegateBuilder1.<>c__DisplayClass15_0.g__RunPipeline|0(IServiceCollection services)
2023-11-03 21:28:10 at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.Invoke(Object instance, IServiceCollection services)
2023-11-03 21:28:10 at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.<>c__DisplayClass8_0.b__0(IServiceCollection services)
2023-11-03 21:28:10 at Microsoft.AspNetCore.Hosting.StartupLoader.ConfigureServicesDelegateBuilder`1.<>c__DisplayClass14_0.g__ConfigureServicesWithContainerConfiguration|0(IServiceCollection services)
2023-11-03 21:28:10 at Microsoft.AspNetCore.Hosting.ConventionBasedStartup.ConfigureServices(IServiceCollection services)
2023-11-03 21:28:10 at Microsoft.AspNetCore.Hosting.WebHost.EnsureApplicationServices()
2023-11-03 21:28:10 at Microsoft.AspNetCore.Hosting.WebHost.Initialize()
2023-11-03 21:28:10 at Microsoft.AspNetCore.Hosting.WebHostBuilder.Build()
2023-11-03 21:28:10 at AgileConfig.Server.Apisite.Program.Main(String[] args) in /src/AgileConfig.Server.Apisite/Program.cs:line 33
这是什么错误呢?

@kklldog
Copy link
Collaborator

kklldog commented Nov 3, 2023

你是用docker跑的还是怎么跑的?你苹果是x86还是arm?

@XiuXiang-GitHub
Copy link
Author

苹果电脑M2芯片 用docker跑的Arm64

@XiuXiang-GitHub
Copy link
Author

在Linux也跑了一下Arm64的镜像
parallels@ubuntu-linux-22-04-02-desktop:~$ sudo docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
0775cb656990 kklldog/agile_config:arm64 "dotnet AgileConfig.…" 15 minutes ago Exited (133) 7 seconds ago agile_config

@kklldog
Copy link
Collaborator

kklldog commented Nov 4, 2023

没M系列的mac,不能测试。。。

@kklldog kklldog reopened this Nov 4, 2023
@XiuXiang-GitHub
Copy link
Author

好吧,那Linux也不能部署吗?是部署Arm64的镜像吧?

@XiuXiang-GitHub
Copy link
Author

虚拟机

@kklldog
Copy link
Collaborator

kklldog commented Nov 4, 2023

好吧,那Linux也不能部署吗?是部署Arm64的镜像吧?

linux x64肯定没问题,大部分玩家都是这个架构。 ARM 的话,我在树莓派 3b 上测试过没问题,其他设备我就没测试过了。不过 理论上 .NET6 跨所有平台,应该是没问题的。

@XiuXiang-GitHub
Copy link
Author

没M系列的mac,不能测试。。。

好吧,那Linux也不能部署吗?是部署Arm64的镜像吧?

linux x64肯定没问题,大部分玩家都是这个架构。 ARM 的话,我在树莓派 3b 上测试过没问题,其他设备我就没测试过了。不过 理论上 .NET6 跨所有平台,应该是没问题的。

我晚上回去试试,谢谢你了

@zatsunen
Copy link

好吧,那Linux也不能部署吗?是部署Arm64的镜像吧?

linux x64肯定没问题,大部分玩家都是这个架构。 ARM 的话,我在树莓派 3b 上测试过没问题,其他设备我就没测试过了。不过 理论上 .NET6 跨所有平台,应该是没问题的。

您好,请问您在树莓派上部署是下源码编译的还是有现有arm的镜像的?

@kklldog
Copy link
Collaborator

kklldog commented Jan 21, 2024

好吧,那Linux也不能部署吗?是部署Arm64的镜像吧?

linux x64肯定没问题,大部分玩家都是这个架构。 ARM 的话,我在树莓派 3b 上测试过没问题,其他设备我就没测试过了。不过 理论上 .NET6 跨所有平台,应该是没问题的。

您好,请问您在树莓派上部署是下源码编译的还是有现有arm的镜像的?

下载 ARM 的就可以,3B 测试过

@zatsunen
Copy link

好吧,那Linux也不能部署吗?是部署Arm64的镜像吧?

linux x64肯定没问题,大部分玩家都是这个架构。 ARM 的话,我在树莓派 3b 上测试过没问题,其他设备我就没测试过了。不过 理论上 .NET6 跨所有平台,应该是没问题的。

您好,请问您在树莓派上部署是下源码编译的还是有现有arm的镜像的?

下载 ARM 的就可以,3B 测试过

请问有相关的连接吗,我这试了很多的镜像都不行,都说平台不支持,我的是4b,树莓派的debian系统

@kklldog
Copy link
Collaborator

kklldog commented Jan 23, 2024

kklldog/agile_config:arm32
kklldog/agile_config:arm64

@zatsunen
Copy link

kklldog/agile_config:arm32 kklldog/agile_config:arm64

好的,谢谢,我试试

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants