-
Notifications
You must be signed in to change notification settings - Fork 97
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
error: "The 'AppId' option must be provided. (Parameter 'AppId')" #17
Comments
This seems to be related to Facebook authentication plugin. Also, this repo did not exist 5 months ago. What version of api plugin did you install? |
Thx a lot for replying so quickly!
I know, - and I'm really glad that it does now :)
We installed the current one - including your last commit 3 days ago. And sorry for not mentioning it earlier: we run the whole thing in Docker / Swarm. |
I cannot reproduce the error. Does the nopCommerce web works without an issue? Does it work when debugging locally without docker? Did you try to uninstall facebook plugin? |
As far as we concerned: yes.
That part works in my colleague F1's local dev environment.
Yes, we tried. That didn't help.
Here's the Dockerfile we're using - eventually, that might help at reproducing.... # create the build instance
FROM mcr.microsoft.com/dotnet/sdk:5.0 AS build
WORKDIR /build
COPY ./.config .
RUN dotnet tool restore
COPY ./paket.dependencies .
COPY ./paket.lock .
RUN dotnet paket restore
RUN cp -r /build/paket-files/github.com/nopSolutions/nopCommerce . \
&& cd / \
&& ln -s /build/nopCommerce/src /src
WORKDIR /src
# restore solution
RUN dotnet restore NopCommerce.sln
WORKDIR /src/Presentation/Nop.Web
# build project
RUN dotnet build Nop.Web.csproj -c Release
# build plugins
WORKDIR /src/Plugins/Nop.Plugin.DiscountRules.CustomerRoles
RUN dotnet build Nop.Plugin.DiscountRules.CustomerRoles.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.ExchangeRate.EcbExchange
RUN dotnet build Nop.Plugin.ExchangeRate.EcbExchange.csproj -c Release
#WORKDIR /src/Plugins/Nop.Plugin.ExternalAuth.Facebook
#RUN dotnet build Nop.Plugin.ExternalAuth.Facebook.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Misc.Sendinblue
RUN dotnet build Nop.Plugin.Misc.Sendinblue.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Payments.CheckMoneyOrder
RUN dotnet build Nop.Plugin.Payments.CheckMoneyOrder.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Payments.Manual
RUN dotnet build Nop.Plugin.Payments.Manual.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Payments.PayPalSmartPaymentButtons
RUN dotnet build Nop.Plugin.Payments.PayPalSmartPaymentButtons.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Payments.PayPalStandard
RUN dotnet build Nop.Plugin.Payments.PayPalStandard.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Pickup.PickupInStore
RUN dotnet build Nop.Plugin.Pickup.PickupInStore.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Shipping.FixedByWeightByTotal
RUN dotnet build Nop.Plugin.Shipping.FixedByWeightByTotal.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Shipping.ShipStation
RUN dotnet build Nop.Plugin.Shipping.ShipStation.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Shipping.UPS
RUN dotnet build Nop.Plugin.Shipping.UPS.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Tax.Avalara
RUN dotnet build Nop.Plugin.Tax.Avalara.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Widgets.FacebookPixel
RUN dotnet build Nop.Plugin.Widgets.FacebookPixel.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Widgets.AccessiBe
RUN dotnet build Nop.Plugin.Widgets.AccessiBe.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Tax.FixedOrByCountryStateZip
RUN dotnet build Nop.Plugin.Tax.FixedOrByCountryStateZip.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Widgets.GoogleAnalytics
RUN dotnet build Nop.Plugin.Widgets.GoogleAnalytics.csproj -c Release
WORKDIR /src/Plugins/Nop.Plugin.Widgets.NivoSlider
RUN dotnet build Nop.Plugin.Widgets.NivoSlider.csproj -c Release
# third party plugins
WORKDIR /build
# api-for-nopcommerce plugin
RUN mkdir -p api-for-nopcommerce \
&& cd api-for-nopcommerce \
&& cp -r /build/paket-files/github.com/stepanbenes/api-for-nopcommerce/Nop.Plugin.Api .
WORKDIR /build/api-for-nopcommerce/Nop.Plugin.Api
RUN dotnet restore Nop.Plugin.Api.csproj \
&& dotnet build Nop.Plugin.Api.csproj -c Release
# publish project
WORKDIR /src/Presentation/Nop.Web
RUN dotnet publish Nop.Web.csproj -c Release -o /app/published
# create the runtime instance
FROM mcr.microsoft.com/dotnet/aspnet:5.0-alpine AS runtime
# add globalization support
RUN apk add --no-cache icu-libs
ENV DOTNET_SYSTEM_GLOBALIZATION_INVARIANT=false
# installs required packages
RUN apk add libgdiplus --no-cache --repository http://dl-3.alpinelinux.org/alpine/edge/testing/ --allow-untrusted
RUN apk add libc-dev --no-cache
# copy entrypoint script
COPY --from=build /build/nopCommerce/entrypoint.sh /entrypoint.sh
RUN chmod 755 /entrypoint.sh
WORKDIR /app
RUN mkdir bin
RUN mkdir logs
COPY --from=build /app/published .
# wait-for-it.sh dependency
RUN apk add bash --no-cache
# call entrypoint script instead of dotnet
ENTRYPOINT "/entrypoint.sh" |
I have managed to reproduce the problem. I have used similar Dockerfile with all plugins including api plugin and facebook authentication plugin and received the same error when trying to access the api. I fixed that by filling the AppId and AppSecret values of facebook plugin with some random strings. After this "fix" the api should work. However, the swagger page was not accessible in release builds. I have commited an update to show swagger UI in Development environment. (set |
Closing as workaround has been provided. |
Will there be an update for this workaround in the future? |
I was getting the same error message. Then I added AppId and AppSecret in FacebookAuthenticationRegistrar.cs Then that error was resolved but still not getting swagger page. Instead when I hit /api it is redirecting me to https://localhost:44369/page-not-found |
Hi Guys,
we have the above problem, - however we try cannot get rid of it so far.
We even tried this → https://www.nopcommerce.com/en/boards/topic/88830/api-plugin-error - but didn't help unfortunately.
Is this a known issue - with a known workaround maybe ?
The text was updated successfully, but these errors were encountered: