How to configure that my image will store in AmazonS3

I have install squidex on IIS, and creating API after loging.
Please help me how I can I configure that appsetting.json to store my image AmazonS3 bucket.

In general I recommend to have a look to the following documentation:

  1. You have to change the asset store type to AmazonS3:

  2. You have to configure access key and secret:

  3. You have to configure bucketName and regionName:

Thats it. My recommendation is to store all your settings in an appsettings.Production.json file as described in the docs.

I have two appsetting json file
1: - appsetting.json
2:- appsettingProduction.json

This is my appsettingProduction.json change, but still not able to upload image in AmazonS3.

Getting message “failed to upload assert”.

"assetStore": {   
    "type": "AmazonS3",
    "folder": {      
      "path": "Assets"
    "AmazonS3": {
       * The name of your bucket.
      "bucketName": "",

       * The optional folder within the bucket.
      "bucketFolder": "assets/images",

       * The region name of your bucket.
      "regionName": "eu-west-2",

       * The access key for your user.
      "accessKey": "XXXXXXXXXXXX",

       * The secret key for your user.
      "secretKey": "XXXXXXXXXXXXX"

Looks okay, when Squidex starts it logs the configuration. This is the first log statement. Can you show me this?

Getting HTTP Error 500.30 when I am changing asset store type to AmazonS3 in my appsettingproduction.json file

It will in squidex folder in IIS?

In the web.config you should see the config for logging.

This is log I found.
Unhandled exception. Squidex.Infrastructure.ConfigurationException: Configure the AssetStore AmazonS3 Bucket with ‘assetStore:amazonS3:bucket’.

at Microsoft.Extensions.Configuration.ConfigurationExtensions.GetRequiredValue(IConfiguration config, String path) in /src/src/Squidex.Infrastructure/Configuration/ConfigurationExtensions.cs:line 46

at Squidex.Config.Domain.AssetServices.<>c__DisplayClass1_0.b__4() in /src/src/Squidex/Config/Domain/AssetServices.cs:line 90

at Microsoft.Extensions.Configuration.ConfigurationExtensions.ConfigureByOption(IConfiguration config, String path, Alternatives options) in /src/src/Squidex.Infrastructure/Configuration/ConfigurationExtensions.cs:line 55

at Squidex.Config.Domain.AssetServices.AddSquidexAssetInfrastructure(IServiceCollection services, IConfiguration config) in /src/src/Squidex/Config/Domain/AssetServices.cs:line 139

at Squidex.Startup.ConfigureServices(IServiceCollection services) in /src/src/Squidex/Startup.cs:line 45

at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor, Boolean wrapExceptions)

at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)

at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.InvokeCore(Object instance, IServiceCollection services)

at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.<>c__DisplayClass9_0.g__Startup|0(IServiceCollection serviceCollection)

at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.Invoke(Object instance, IServiceCollection services)

at Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.<>c__DisplayClass8_0.b__0(IServiceCollection services)

at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.UseStartup(Type startupType, HostBuilderContext context, IServiceCollection services)

at Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.<>c__DisplayClass12_0.b__0(HostBuilderContext context, IServiceCollection services)

at Microsoft.Extensions.Hosting.HostBuilder.CreateServiceProvider()

at Microsoft.Extensions.Hosting.HostBuilder.Build()

at Squidex.Program.Main(String[] args) in /src/src/Squidex/Program.cs:line 22

Please format your code correctly.

Seems there is a bug in the default settings. Try "bucket": "my-bucket" instead.

in my appsettingproduction.json.

“AmazonS3”: {
* The name of your bucket.
“bucketName”: “”,

Is it wrong?

Yes, try "bucket" instead of "bucketName"

Thanks its work.
I think you should also change this in default appsetting.json provide by squidex.

1 Like

Yes, I already did it.