Which version of Adobe Illustrator are you using?
Try this and see if it works for you.
Create a rectangle with a gradient e.g. like this:
(Remember, the first swatch in the gradient should have the same value as the last one.)
Now create a circle with a two-color radial gradient.
With the circle selected go to Object=Expand...
Select these options:
Now you should see a layer structure like below.
With a mesh and a clipping path.
Delete the clipping path.(Selected in the screenshot).
Now the circle has no clipping path, and so it should appear larger.
With your Point Selection tool, select a point related to the inner circle. Then hit delete.
Before you continue, remember to check Distort Linear Gradient Fills inside Object= Envelope Distort= Envelope Options.
Now, select both the Circle, and the rectangle. Go to Object=Envelope Distort=Make With Top Object.
You should now have the result you where looking for. :)
If you want to edit your gradient you can switch editing area with these: located in the upper-left corner of your screen: