my-cloud-devops-consulting 1.1.202507211722__py3-none-any.whl → 1.1.202507211816__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
app.py CHANGED
@@ -278,11 +278,27 @@ oauth.register(
278
278
  ################################################
279
279
 
280
280
  # Configure a login route to direct to Amazon Cognito managed login for authentication with a redirect to an authorize route.
281
+ # @app.route('/login/cognito')
282
+ # def login_cognito():
283
+ # session.pop('user', None)
284
+ # redirect_uri = url_for('authorize', _external=True)
285
+ # print("🧭 Redirect URI being used:", redirect_uri) # <--- add this
286
+ # return oauth.oidc.authorize_redirect(
287
+ # redirect_uri,
288
+ # prompt='login'
289
+ # )
290
+
281
291
  @app.route('/login/cognito')
282
292
  def login_cognito():
283
293
  session.pop('user', None)
284
- redirect_uri = url_for('authorize', _external=True)
285
- print("🧭 Redirect URI being used:", redirect_uri) # <--- add this
294
+
295
+ # Determine redirect URI based on environment
296
+ if '1beto.com' in request.host:
297
+ redirect_uri = 'https://1beto.com/authorize' # force HTTPS for production
298
+ else:
299
+ redirect_uri = url_for('authorize', _external=True) # use localhost in dev
300
+
301
+ print("🧭 Redirect URI being used:", redirect_uri)
286
302
  return oauth.oidc.authorize_redirect(
287
303
  redirect_uri,
288
304
  prompt='login'
@@ -291,7 +307,6 @@ def login_cognito():
291
307
 
292
308
 
293
309
 
294
-
295
310
  # The OAuth module collects the access token and retrieves user data from the Amazon Cognito userInfo endpoint. Configure an authorize route to handle the access token and user data after authentication.
296
311
  @app.route('/authorize')
297
312
  def authorize():
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: my-cloud-devops-consulting
3
- Version: 1.1.202507211722
3
+ Version: 1.1.202507211816
4
4
  Summary: This is my consulting website for Cloud & DevOps services.
5
5
  Home-page: https://github.com/Betrand1999/project-root
6
6
  Author: Betrand Mutagha
@@ -0,0 +1,5 @@
1
+ app.py,sha256=smZ-B3_9YbSudiyFr1LGtyO3ENbwrGg1LG7NRSBq2gE,11803
2
+ my_cloud_devops_consulting-1.1.202507211816.dist-info/METADATA,sha256=j1UW8q6HUdqRFf09r1kKaOuTvoedGp94QHEuj41pklM,785
3
+ my_cloud_devops_consulting-1.1.202507211816.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
4
+ my_cloud_devops_consulting-1.1.202507211816.dist-info/top_level.txt,sha256=io9g7LCbfmTG1SFKgEOGXmCFB9uMP2H5lerm0HiHWQE,4
5
+ my_cloud_devops_consulting-1.1.202507211816.dist-info/RECORD,,
@@ -1,5 +0,0 @@
1
- app.py,sha256=JhYl1My8hHBBqNLDarRAyNdJ6iHjya0b8grK4pZkU9U,11290
2
- my_cloud_devops_consulting-1.1.202507211722.dist-info/METADATA,sha256=_ZNI-1aHIjMHa7Zj6b6q32PZUpBk59vemmSpN1lZ-RE,785
3
- my_cloud_devops_consulting-1.1.202507211722.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
4
- my_cloud_devops_consulting-1.1.202507211722.dist-info/top_level.txt,sha256=io9g7LCbfmTG1SFKgEOGXmCFB9uMP2H5lerm0HiHWQE,4
5
- my_cloud_devops_consulting-1.1.202507211722.dist-info/RECORD,,